2

I am developing an app for a project that takes data from a scanned USDL (Using BlinkID) and inputs data such as: First Name, Last Name, Middle Name, DOB, Sex, and address into seperate text boxes on a separate view controller. Then when hitting "OK" takes them to another view controller with other options that I will be creating.

I am stuck though. I can't seem to transfer the data from scanned USDL into text boxes on a separate View Controller. I am able to import the data into Xcode when scanned, but I want to be able to switch views automatically after scan and have the app auto fill the textboxes labeled: FIRST NAME, LAST NAME, ADDRESS, DOB, SEX, etc.

rmaddy
  • 314,917
  • 42
  • 532
  • 579
Genius
  • 55
  • 6

1 Answers1

4

Try the following steps:

  • Start with BlinkID-sample app from Github.
  • Create a new view controller (let's call it USDLResultController) where you want the results to be presented. Add text boxes to that view controller and implement the whole UI
  • Add a public property to USDLResultController (in the header file) as follows: @property (nonatomic, strong) PPUsdlRecognizerResult *usdlRecognizerResult;
  • In the view controller which calls the scanning, in the callback where you receive the scanning result (typically it's scanningViewController:didOutputResults:), check if you received an USDL recognizer result
  • If you received it, instantiate USDLResultController (either from storyboard, either in code), and set the usdlRecognizerResult to the result you received
  • In viewWillAppear (or some other similar method) of the USDLResultController populate the text boxes with values from usdlRecognizerResult property.

If you still need help after this, please send a link to the project where you're implementing this so we can take a look.

Disclaimer: I'm working for the BlinkID team.

Cerovec
  • 1,273
  • 10
  • 19