본문 바로가기

iPhone Dev

[XCode] Type "ViewController" does not conform to protocol 'UITableViewDataSource' 에러

   


Type "ViewController" does not conform to protocol 'UITableViewDataSource' 요딴 에러가 나면 아래 2가지 기본 함수를 선언안해줘서 그렇다.

func tableView(tableView: UITableView, numberOfRowsInSection section: Int) -> Int 

func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell



UITableViewDataSource 소스 참고.