私は現在、1つの列と静的な情報を持つテーブルビューを持っています。私は、サーバーから更新される情報を持つ2番目の列を追加したいと思います。ここで私のuitableviewに2番目の列を追加したいと思います。どうやって?
は今私のコードです:
var array = ["Daskalakis Athletic Center" , "Hagerty Library", "Hans Dining Hall", "Northside Dining Hall", "Urban Eatery", "Creese Student Center", "Cyber Learning Center", "Rush Advisors"]
func tableView(tableView: UITableView, numberOfRowsInSection section: Int) -> Int
{
return array.count
}
func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell
{
let cell: UITableViewCell! = self.ListView
.dequeueReusableCellWithIdentifier("cell") as UITableViewCell!
cell.textLabel!.text = self.array[indexPath.row]
return cell
}
最初にあなたの質問をクリアしてください。あなたのテーブルにcoloumを追加すると、まず配列を追加できます。 –
どういう意味ですか? –
テーブルで何をしたいですか? –