1
我是Swift的新手,也沒有開發背景經驗。我想在Swift中使用簡單的表格視圖,但在源文件中不斷收到編輯器佔位符錯誤。編輯器佔位符在簡單的UITableView源文件錯誤
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: "cell", for: <#T##IndexPath#>) as! CustomCell
cell.photo.image = images[indexPath.row]
cell.Name.text = names[indexPath.row]
cell.Job.text = jobs[indexPath.row]
return cell
}
乾杯我認爲它只是它的方式複製和粘貼! let cell = tableView.dequeueReusableCell(withIdentifier:「cell」,for:IndexPath)as! CustomCell –
這是我得到錯誤的線!!! –
indexPath,而不是IndexPath – Mozahler