createTextCaptureServiceWithDelegate API is always returning nil

  • Last Post 05 September 2017
Rahul Jain posted this 30 August 2017

I am trying to integrate the Abbyyrtrsdk into my sample POC application just to see how i can get the text from the scanned image.

I tried to run the "sample-textcapture" objective-c application, there i am able to scan text successfully.

When i copied all resources and framework into my POC application and did the installation as per the installation guide and sample project setting reference i am facing issues when i am trying to fetch the text capture service from the engine. I am always getting nil as refrence due to that i am not able to use the text recognition service.

Here is the code that i am using to get the reference of the text capture service :

NSString* licensePath = [[[NSBundle mainBundle] bundlePath] stringByAppendingPathComponent:@"AbbyyRtrSdk.license"];

_engine = [RTREngine sharedEngineWithLicenseData:[NSData dataWithContentsOfFile:licensePath]];

_textCaptureService = [_engine createTextCaptureServiceWithDelegate:self];

[_textCaptureService setRecognitionLanguages:[NSSet setWithObject:@"English"]];

IvanPopov posted this 05 September 2017

First of all, please check once again that you followed the steps listed in Developer’s Guide → Guided Tour → How to Add the Library to your Xcode Project.   If the issue persists, please provide some additional information:

  • iOS version that you are using/testing on.
  • RTR SDK build number, which you can find in the Readme.html file included in the distribution.
  • Step-by-step description of how to reproduce this behavior.