【发布时间】:2014-03-19 09:34:05
【问题描述】:
- (IBAction)ButtonPress:(UIButton *)sender {
- (void) ButtonPressed: (id) sender
{
if (sender != self.done)
return;
if (self.zahlencode.text.length > 0)
{
zz =[self.zahlencode.text intValue];
if(zz == a)
{
[self performSegueWithIdentifier:@"1" sender:self];
}
}
}
}
在 Void ButtonPressed 有一个错误提示 Use of undeclared ButtonPressed
如果我在没有应用程序构建崩溃的操作的情况下使用它。我放了一个异常断点,它给出了这个错误
2014-03-19 10:19:53.295 AbteiRD[8873:70b] Cannot find executable for CFBundle 0x8a91780 </Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.0.sdk/System/Library/AccessibilityBundles/CertUIFramework.axbundle> (not loaded)
(lldb)
【问题讨论】:
-
你忘了大括号 } 吗?正确的必须是:
- (IBAction)ButtonPress:(UIButton *)sender { } -
哦,我想我一定是在虚无的尽头。测试一下
-
你为什么把-(void)方法放在IBAction里面?
-
为什么我现在有 -1 我做错了什么?抱歉,这是我在这里的第一个问题。
标签: ios objective-c xcode uibutton ibaction