Re: Find words in document and highlight with annotations
Started by Otis at 10-18-2005 11:11. Topic has 9 replies.
|
|
10-18-2005, 11:11
|
Otis

Joined on 10-19-2004
Charlotte, NC
Posts 331
|
|
|
The attached VB.NET example will allow you to load an image and perform OCR on it. You can then specify a word you wish to search for within the image. If the word is found, a highlight annotation will be displayed over the word.
Otis Goodwin LEAD Developer Support
|
|
|
|
|
Report
|
|
|
|
09-13-2007, 15:36
|
drjones
Joined on 09-13-2007
Posts 5
|
Re: Find words in document and highlight with annotations
|
 
 
|
|
|
Hi: Is there a VC++ version of this code? Any pointers would be useful. Thanks. Anand
|
|
|
|
|
Report
|
|
|
|
09-14-2007, 11:15
|
jigar

Joined on 08-22-2007
Posts 594
|
Re: Find words in document and highlight with annotations
|
 
 
|
|
|
Hello,
Unfortunately, we don't have one available in VC++, but the code flow is the same. You just have to use the corresponding functions available in the API library. Our C++ Class Library is very close to this. If you have anything specific that you have trouble with we can help you out with that.
Thank You
LEADTOOLS Technical Support
|
|
|
|
|
Report
|
|
|
|
09-14-2007, 11:56
|
drjones
Joined on 09-13-2007
Posts 5
|
Re: Find words in document and highlight with annotations
|
 
 
|
|
|
Thanks, I could figure it out. But when I output the recognized word to a file, it prints out hex (even if I use the %s qualifier). Am i missing anything obvious? Thanks
|
|
|
|
|
Report
|
|
|
|
09-14-2007, 12:31
|
jigar

Joined on 08-22-2007
Posts 594
|
Re: Find words in document and highlight with annotations
|
 
 
|
|
|
Hello,
Can you post the code snippet which gets a word from the recognized page and prints it to the console/file. I'm thinking it's because it might be returning in Unicode char set, but I'm not 100% sure on it.
LEADTOOLS Technical Support
|
|
|
|
|
Report
|
|
|
|
09-14-2007, 12:58
|
drjones
Joined on 09-13-2007
Posts 5
|
Re: Find words in document and highlight with annotations
|
 
 
|
|
|
yes it is returning the unicode charset. I tried: myfile << pRecogWords[i].szWord; // (prints unicode) myfile << printf("%s",pRecogWords[i].szWord); // (prints a single digit)
and similar combinations.
Thanks
|
|
|
|
|
Report
|
|
|
|
09-14-2007, 15:06
|
jigar

Joined on 08-22-2007
Posts 594
|
Re: Find words in document and highlight with annotations
|
 
 
|
|
|
Yes, the szWord is of type L_WCHAR which is the same as WCHAR. If you want to conver it to a LPCSTR you can use the WideCharToMultiByte() function in windows.h. Documentation for it is here: http://msdn2.microsoft.com/en-us/library/ms776420.aspx
LEADTOOLS Technical Support
|
|
|
|
|
Report
|
|
|
|
09-27-2007, 10:21
|
GregR

Joined on 05-31-2006
In House
Posts 2,251
|
|
|
This demo has been ported to version 15 in VB.NET 2005.
Greg Ross LEADTOOLS Technical Support
|
|
|
|
|
Report
|
|
|
|
09-27-2007, 10:22
|
GregR

Joined on 05-31-2006
In House
Posts 2,251
|
|
|
This demo has been ported to version 15 with the C++ Class Library
Greg Ross LEADTOOLS Technical Support
|
|
|
|
|
Report
|
|
|
|
06-30-2009, 16:06
|
GregR

Joined on 05-31-2006
In House
Posts 2,251
|
Re: Find words in document and highlight with annotations
|
 
 
|
|
|
For 16.0 and 16.5 versions, please visit http://support.leadtools.com/CS/forums/24558/ShowPost.aspx
Greg Ross LEADTOOLS Technical Support
|
|
|
|
|
Report
|
|
|
|
|
LEAD Support Fo... » Developer » DotNet » Re: Find words in document and highlight with annotations
|
|
Copyright LEAD Technologies, Inc. 2009
