我安装了 SDK (2.2.7) 并将所有框架包含在 xCode (4.6.2) 项目中。每当我尝试扫描代码时,它都会崩溃:
int main(int argc, char *argv[])
{
@autoreleasepool {
return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
}
}
扫描视图的吸气剂
- (ScanditSDKBarcodePicker *)scanPicker
{
if (!_scanPicker)
{
_scanPicker = [[ScanditSDKBarcodePicker alloc] initWithAppKey: SCANDIT_APP_KEY];
UIBarButtonItem *guestButton = [[UIBarButtonItem alloc] initWithTitle:@"List" style:UIBarButtonItemStylePlain target:self action:@selector(choseFromList:)];
_scanPicker.navigationItem.rightBarButtonItem = guestButton;
UIBarButtonItem *cancelButton = [[UIBarButtonItem alloc] initWithTitle:@"cancel" style:UIBarButtonItemStylePlain target:self action:@selector(cancelPicker:)];
_scanPicker.navigationItem.leftBarButtonItem = cancelButton;
_scanPicker.overlayController.delegate = self;
[_scanPicker startScanning];
}
return _scanPicker;
}
呈现它的代码
- (void)presentScanditViewController
{
UINavigationController *navi = [[UINavigationController alloc] initWithRootViewController:self.scanPicker];
[self presentViewController:navi animated:YES completion:nil];
}
我也检查了应用程序键,有人有同样的问题吗?