Take the following steps to create a project and add some code that loads and reads the machine-printed information on a bank check image.
In the Solution Explorer window, right-click on the References folder, and select "Add Reference..." from the context menu. In the "Add Reference" dialog box, select the ".NET" tab, browse to the "<INSTALLDIR>\Bin\Dotnet\Win32" folder (or "<INSTALLDIR>\Bin\Dotnet4\Win32" if you are going to use .NET 4), and select the following DLLs:
Leadtools.dll
Leadtools.Codecs.dll
Leadtools.Codecs.Cmp.dll
Leadtools.Forms.Commands.dll
Leadtools.Document.Writer.dll
Leadtools.Ocr.dll
Leadtools.Ocr.LEADEngine.dll
Add the following lines at the beginning of the file:
using Leadtools;
using Leadtools.Codecs;
using Leadtools.Forms.Commands;
using Leadtools.Ocr;
string MY_LICENSE_FILE = "d:\\temp\\TestLic.lic";
string MY_DEVELOPER_KEY = "xyz123abc";
RasterSupport.SetLicense(MY_LICENSE_FILE, MY_DEVELOPER_KEY);
string chequePath = @"C:\Users\Public\Documents\LEADTOOLS Images\BankCheck.jpg";
RasterCodecs codecs = new RasterCodecs();
RasterImage image = codecs.Load(chequePath);
BankCheckReader chequeReader = new BankCheckReader();
using (IOcrEngine engine = OcrEngineManager.CreateEngine(OcrEngineType.LEAD, false))
{
engine.Startup(codecs, null, null, null);
chequeReader.OcrEngine = engine;
chequeReader.ProcessImage(image);
engine.Shutdown();
}
foreach (KeyValuePair<string, BankCheckField> kvp in chequeReader.Results)
{
Console.WriteLine(kvp.Key + "\t\t" + kvp.Value.Text);
}
image.Dispose();
codecs.Dispose();
Console.ReadLine();
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document