私はSwiftでサイドバーを構築しています。 そして私は、このコードでは、このエラーを得た:タイプ 'UIColor'の値を 'String'に割り当てることができません。
override func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell {
var cell:UITableViewCell! = tableView.dequeueReusableCellWithIdentifier("cell")! as UITableViewCell
if cell == nil{
cell = UITableViewCell(style: UITableViewCellStyle.Default, reuseIdentifier: "Cell")
cell!.backgroundColor = UIColor.clearColor()
cell!.textLabel!.text = UIColor.darkTextColor()
}
// Configure the cell...
return cell
}
だから、実際には同じ問題を抱えているこのプラットフォーム上の誰かがそこにあります。ソリューションでは、彼らは私がUIColor.darkTextColor()
背後!
を追加する必要がありますが、言った、私は私が!
エラーを削除する必要が別のエラーがあることを行う場合の行にあります!
セル.textLabel!
あなたは何が起こっているのか知っていますか?
エラーメッセージは何ですか? –
@JeffPuckettIIタイトルに? – Hamish