←Select platform

FieldType Property

Summary
The current BankCheckField type that will be or has been processed.
Syntax
C#
C++/CLI
Python
public BankCheckFieldType FieldType { get; } 
public: 
property BankCheckFieldType FieldType { 
   BankCheckFieldType get(); 
} 
FieldType # get  (ProgressEventArgs) 

Property Value

Type of field that will be or has been processed.

Example
C#
using Leadtools; 
using Leadtools.Codecs; 
using Leadtools.Forms.Common; 
using Leadtools.Ocr; 
using Leadtools.Forms.Commands; 
 
 
public void TestBankCheckReader() 
{ 
   // Initialize the RasterCodecs class 
   RasterCodecs codecs = new RasterCodecs(); 
 
   // Initialize the BankCheckReader class 
   BankCheckReader checkReader = new BankCheckReader(); 
 
   // The bank cheque image 
   string chequePath = Path.Combine(LEAD_VARS.ImagesDir, "BankCheck.jpg"); 
   RasterImage image = codecs.Load(chequePath); 
 
   IOcrEngine ocrEngine = OcrEngineManager.CreateEngine(OcrEngineType.LEAD); 
   ocrEngine.Startup(codecs, null, null, LEAD_VARS.OcrLEADRuntimeDir); 
   // Assign Engine to Reader 
   checkReader.OcrEngine = ocrEngine; 
 
   //Set MICR code type 
   checkReader.MicrFontType = BankCheckMicrFontType.E13b; 
 
   // handle Process Event 
   checkReader.Process += new EventHandler<ProgressEventArgs>(reader_Processed); 
 
   // Process Image 
   checkReader.ProcessImage(image); 
 
   ocrEngine.Shutdown(); 
} 
 
void reader_Processed(object sender, ProgressEventArgs e) 
{ 
   Console.WriteLine(string.Format("State      : {0}%", e.State)); 
   Console.WriteLine(string.Format("Percentage : {0}%", e.Percentage)); 
   Console.WriteLine(string.Format("FieldType  : {0}%", e.FieldType.ToString())); 
 
   if (e.State == ProcessState.Finish) 
   { 
      BankCheckReader reader = sender as BankCheckReader; 
      foreach (var value in reader.Results) 
      { 
         LeadRect bounds = value.Value.Bounds; 
         Console.WriteLine(string.Format("Field Name      : {0}", value.Key)); 
         Console.WriteLine(string.Format("Field Value     : {0}", value.Value.Text)); 
         Console.WriteLine(string.Format("Field Bounds    : {0},{0},{0},{0}", bounds.X.ToString(), bounds.Y.ToString(), bounds.Width.ToString(), bounds.Height.ToString())); 
         Console.WriteLine("************************************"); 
      } 
   } 
} 
 
 
static class LEAD_VARS 
{ 
   public const string ImagesDir = @"C:\LEADTOOLS22\Resources\Images"; 
   public const string OcrLEADRuntimeDir = @"C:\LEADTOOLS22\Bin\Common\OcrLEADRuntime"; 
} 
Requirements

Target Platforms

Help Version 22.0.2023.4.12
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.Forms.Commands Assembly
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.