This topic and its replies were posted before the current version of LEADTOOLS was released and may no longer be applicable.
#1
Posted
:
Thursday, June 8, 2006 4:22:28 PM(UTC)
Groups: Registered
Posts: 5
Hi
I am using LeadTools 14.5 Evaluation version.
My program would call a method to recognize the wording of a image when I click a button.
The method runs successfully.
However, after I recognize several image, it crashes with the error "General Protection Fault in the engine"
I use an error handler to catch this exception and then I recall the function.
I runs successfully again. However, after recognizing several images, again, it crashes.
Here is my code segment and the program always crashes in the statement:
result = _rasterOcr.SaveResultsToMemory();
public string Recognition()
{
string currentPath = Application.StartupPath;
string result = string.Empty;
if (File.Exists(currentPath + "\\nec.rdf"))
File.Delete(currentPath + "\\nec.rdf");
try
{
_rasterOcr.RecognitionDataFileName = currentPath + "\\nec.rdf";
_rasterOcr.Recognize(0, 1);
result = _rasterOcr.SaveResultsToMemory();
}
catch (RasterOcrException ex)
{
result =
string.Empty;
}
return result;
}
Thank so much ~
#2
Posted
:
Monday, June 12, 2006 12:27:04 AM(UTC)
Groups: Registered, Tech Support
Posts: 1,326
Was thanked: 1 time(s) in 1 post(s)
Hello,
When exactly did you start to get this error? The chances of the same thing causing the crash are pretty small.
May be this issue is related to problem with the setup installation. Try to uninstall, reboot and then reinstall LEADTOOLS SDK and retry the same issue.
Also, please try to check the same issue onto two different machines and let me know how it goes.
Can you please provide me with sample images that show the problem (in a ZIP file)?
Thanks,
Maen Badwan
LEADTOOLS Technical Support
#3
Posted
:
Monday, June 12, 2006 11:14:11 PM(UTC)
Groups: Registered
Posts: 5
Hi
I have uninstall, reboot and then reinstall the Leadtools SDK but the problem cannot be solved.
Here is one of the sample image file which causes the problem, but the problem not always happens. It only occurs after several recognizations, and I found that, the problem not occurs randomly (as I get the same error pattern for the same image).
Thank you for your kind concern.
#4
Posted
:
Wednesday, June 14, 2006 4:15:30 AM(UTC)
Groups: Registered, Tech Support
Posts: 1,326
Was thanked: 1 time(s) in 1 post(s)
Hello,
Thank you for your cooperation.
I checked this issue using the latest LEADTOOLS eval setup and didn't notice the same problem.
I am attaching the project that I used to check this issue. The project loops through the ocr.SaveResultsToMemory method 20 times.
Please download and reinstall the evaluation version of LEADTOOLS raster imaging pro for .Net by using the following URL:
http://www.leadtools.com/evaldownloads/v14/eval/Leadtoolsdotneteval.exe
After downloading the setup, please do the following:
- Uninstall LEADTOOLS .Net SDK from your machine.
- Reboot your machine.
- Reinstall the new evaluation setup and retry the same issue.
Please let me know how it goes.
Regards,
Maen Badwan
LEADTOOLS Technical Support
#5
Posted
:
Wednesday, June 14, 2006 4:35:04 PM(UTC)
Groups: Registered
Posts: 5
Hi,
Thank you for your reply.
After I compared the code with yours and mine, I find that the different is like that:
<Yours>
for (int i = 0; i < 20; i++)
{
ocr.Startup( );
//recognization process
ocr.Shutdown( );
}
<Mine>
ocr.Startup( );
for (int i = 0; i < 20; i++)
{
//recognization process
}
ocr.Shutdown( );
After I changed my code as yours, it works fine~~~(although it is a bit slower [:P]).
Thanks alot~ [Y]
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.