2012-06-06 80 views
1

每當我打電話無法識別的選擇發送到實例,原因

self.gLViewController = [[GLViewController alloc] initWithNibName:@"GLViewController" bundle:nil]; 
     [self.navigationController pushViewController:self.gLViewController animated:YES]; 

我得到以下錯誤:

2012-06-06 15:22:50.329 NavApp[5357:707] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[MiniGamesViewController setGLViewController:]: unrecognized selector sent to instance 0x1f6aa730' 
*** First throw call stack: 
(0x353b788f 0x3775e259 0x353baa9b 0x353b9915 0x35314650 0xb14cf 0x353113fd 0x32e06e07 0x32e06dc3 0x32e06da1 0x32e06b11 0x32e07449 0x32e0592b 0x32e05319 0x32deb695 0x32deaf3b 0x36faa22b 0x3538b523 0x3538b4c5 0x3538a313 0x3530d4a5 0x3530d36d 0x36fa9439 0x32e19cd5 0xaeae5 0x60ce4) 
terminate called throwing an exception(lldb) 

誰能幫告訴我到底這是什麼意思嗎?我一直在這個工作一個堅實的小時,並沒有取得任何進展。非常感謝幫助!

+0

在GLViewController如果您使用的界面生成器,確保GLViewController的查看鏈接到文件所有者 – self

回答

1

你將不得不合成財產 在MiniGamesViewController .M

//After the implementation 
@implementation MiniGamesViewController 
//Add this line 
@synthesize gLViewController; 
+0

編輯:看的喜歡我忘記了......現在添加。 –

+0

好吧,那個工作......不能相信我忘了! –

+0

還有比你想象:),請不要忘記給予好評和/或接受的答案,如果它幫助你:) –

相關問題