Nicomsoft OCR: Developer's Guide


Blk_GetLineCnt


Syntax

C++:int Blk_GetLineCnt(HBLK BlkObj)
C#:int Blk_GetLineCnt(int BlkObj)
Visual Basic:Function Blk_GetLineCnt(ByVal BlkObj As Integer) As Integer
Java:int Blk_GetLineCnt(HBLK BlkObj)
Delphi:function Blk_GetLineCnt(BlkObj:HBLK):integer


Description

Retrieves the total number of text lines in the specified block after performing OCR with the Img_OCR function.


Parameters

BlkObj [IN] – the Block object. You can also specify the Image object if you want to work with the global list of text lines for the entire image.


Return value

If success, the total number of text lines; otherwise, an error code.


Remarks

The OCRSTEP_OCR step must be executed before calling this function.


Example

See the sample code for the Blk_GetCharCnt or Img_GetBlockCnt functions.