One time success other error

  • 1.2K Views
  • Last Post 15 July 2016
thabet idris posted this 11 July 2016

i want to apply OCR ABBY Arabic with 4 photos at same time , thi is my code C#:

string language = "Arabic"; ProcessingSettings settings = new ProcessingSettings(); settings.SetLanguage(language);
settings.SetOutputFormat(OutputFormat.txt);

            string[] sourceFiles = new String[] { @"C:\CINPROCESSING\Prenom.jpg", @"C:\CINPROCESSING\nom.jpg", @"C:\CINPROCESSING\numcin.jpg", @"C:\CINPROCESSING\Date.jpg" } ;

            string[] outputFileBase = new String[] { @"C:\CINPROCESSING\Prenom.txt", @"C:\CINPROCESSING\nom.txt", @"C:\CINPROCESSING\numcin.txt", @"C:\CINPROCESSING\Date.txt" };

            for (int fileIndex = 0; fileIndex < sourceFiles.Length; fileIndex++)
            {
                string filePath = sourceFiles[fileIndex];
                OcrSdkTask task = restClient.ProcessImage(sourceFiles[fileIndex], settings);
                task = waitForTask(task, restClient);
                restClient.DownloadResult(task, outputFileBase[fileIndex]);
            }

Sometimes I have results successfully, sometimes i have ERROR!!!

ERROR: C:\CINPROCESSING\Prenom.jpg FileNOTFound !!! !!!Same ERROR for others photos : C:\CINPROCESSING\nom.jpg, .. And i have this photo and others , all are correct in the PATH!!

How can i fix it?

Thanks,

Order By: Standard | Newest | Votes
Oksana Serdyuk posted this 13 July 2016

It seems there is something wrong in the logic of your application. Please make sure that your images are free from previous recognition processes and there are no any conflicts between different processes that are operating with the same files.

Also I would recommend you to use any HTTP debugger (for example, Fiddler) to debug your code. It can be very useful during developing and for identifying the issues.

thabet idris posted this 15 July 2016

Very thanks,

I must make Full permission of pictures

Thanks,

Close