2014-01-27 3 views
0

Я новичок в Xcode, и я получаю эту ошибку, и я не совсем уверен, что это значит и как это исправить:Xcode Ошибка с slideviewcontroller

Ниже приводится ссылка на код ошибки (http://pastebin.com/Y74frJxa) .. .

2014-01-26 00:23:16.183 SidebarDemo[677:70b] *** Assertion failure in -[UITableView dequeueReusableCellWithIdentifier:forIndexPath:], /SourceCache/UIKit_Sim/UIKit-2903.23/UITableView.m:5261 
2014-01-26 00:23:16.186 SidebarDemo[677:70b] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'unable to dequeue a cell with identifier map - must register a nib or a class for the identifier or connect a prototype cell in a storyboard' 
*** First throw call stack: 
(
0 CoreFoundation 0x0222a5e4 __exceptionPreprocess + 180 
1 libobjc.A.dylib 0x016a48b6 objc_exception_throw + 44 
2 CoreFoundation 0x0222a448 +[NSException raise:format:arguments:] + 136 
3 Foundation 0x01077fee -[NSAssertionHandler handleFailureInMethodbject:file:lineNumber:description:] + 116 
4 UIKit 0x002e9ed3 -[UITableView dequeueReusableCellWithIdentifier:forIndexPath:] + 170 
5 SidebarDemo 0x0000d6e9 -[SidebarViewController tableView:cellForRowAtIndexPath:] + 233 
6 UIKit 0x002f461f -[UITableView _createPreparedCellForGlobalRow:withIndexPath:] + 412 
7 UIKit 0x002f46f3 -[UITableView _createPreparedCellForGlobalRow:] + 69 
8 UIKit 0x002d8774 -[UITableView _updateVisibleCellsNow:] + 2378 
9 UIKit 0x002ebe95 -[UITableView layoutSubviews] + 213 
10 UIKit 0x00270267 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 355 
11 libobjc.A.dylib 0x016b681f -[NSObject performSelector:withObject:] + 70 
12 QuartzCore 0x029ed2ea -[CALayer layoutSublayers] + 148 
13 QuartzCore 0x029e10d4 _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 380 
14 QuartzCore 0x029e0f40 _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 26 
15 QuartzCore 0x02948ae6 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 294 
16 QuartzCore 0x02949e71 _ZN2CA11Transaction6commitEv + 393 
17 QuartzCore 0x02a06430 +[CATransaction flush] + 52 
18 UIKit 0x00221dc9 _afterCACommitHandler + 131 
19 CoreFoundation 0x021f24ce __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 30 
20 CoreFoundation 0x021f241f __CFRunLoopDoObservers + 399 
21 CoreFoundation 0x021d0344 __CFRunLoopRun + 1076 
22 CoreFoundation 0x021cfac3 CFRunLoopRunSpecific + 467 
23 CoreFoundation 0x021cf8db CFRunLoopRunInMode + 123 
24 GraphicsServices 0x027c59e2 GSEventRunModal + 192 
25 GraphicsServices 0x027c5809 GSEventRun + 104 
26 UIKit 0x00205d3b UIApplicationMain + 1225 
27 SidebarDemo 0x0000c76d main + 141 
28 libdyld.dylib 0x0386a70d start + 1 
) 
libc++abi.dylib: terminating with uncaught exception of type NSException 
(lldb) 

Спасибо всем, кто помогает заранее!

+0

Он говорит, что отсутствует ** ** Identifier клетки. –

ответ

0

Ошибка: вам не хватает reuseIdentifier. Для этого просто выберите tableViewCell в yourTableView в Раскадровка и установить reuseIdentifier в атрибуты Инспектор.

использование, что повторное использование идентификатора в cellForRowAtIndex способом, как

[tableView dequeueReusableCellWithIdentifier:@"xxxx"] 
Смежные вопросы