Documentation / MRZ Scanner 1.x (archive) / iOS
1.Copy MRZScannerSDK.framework into your project's folder and add it in your project as embedded binary.
2.Import the scanner by adding this line of code:
#import <MRZScannerSDK/MRZScanner.h>
3. Start the scanner with the following code:
MRZScannerController * mrzSannerController = [MRZScannerController new];
[mrzSannerController registerLicenseWithKey:@"Licence_key"];
mrzSannerController.delegate = self;
UIViewController *currentViewController = self.navigationController ? self.navigationController : self;
[currentViewController addChildViewController:mrzSannerController]; [mrzSannerController initUI:currentViewController];
4. To get the result, conform to the protocol MRZScannerDelegate and implement:
Objective-C
- (void) successfulScanWithResult:(MRZResultDataModel*)result
Swift
func successfulScan(withResult result: MRZResultDataModel!)
5. Add the following row in your Info.plist file:
key: NSCameraUsageDescription
value: MRZ Scanner requires using camera
6. In Build Settings set Enable Bitcode to NO
Updated Jun 25, 2020 · Questions? Ask us