L_Doc2ImportZonesExt

#include "ltdoc2.h"

L_LTDOC2_API L_INT L_Doc2ImportZonesExt(hDoc, nDocId, nPageIndex, pszFileName)

Imports the user zone list from a zone file into the specified page.

Parameters

L_HDOC2 hDoc

Handle to the OCR document.

L_INT nDocId

Document ID created by calling L_Doc2CreateDocument.

L_INT nPageIndex

Zero-based index of the page into which the settings will be loaded.

L_TCHAR * pszFileName

Character string containing the name of the zone file that contains the zones to import.

Returns

Value Meaning
SUCCESS The function was successful.
< 1 An error occurred. Refer to Return Codes.

Comments

Calling this function removes any zone list already attached to the specified page.

To save the zone list to a file, call the L_Doc2ExportZones / L_Doc2ExportZonesExt function.

Required DLLs and Libraries

See Also

Functions

Topics

Example

L_INT Doc2ImportZonesExampleExt(L_HDOC2 hDoc, L_INT nDocId, L_INT nPageIndex, L_TCHAR * pszZoneFile) 
{ 
   L_INT nRet; 
   nRet = L_Doc2ImportZonesExt(hDoc, nDocId, nPageIndex, pszZoneFile); 
   if (nRet == SUCCESS) 
      MessageBox(NULL, TEXT("Imports the zone file into the specified page."), TEXT("Notice!"), MB_OK); 
   else 
      return nRet; 
 
   //... 
   // work with zones... 
   //... 
 
   // exports page zone list to Zone file... 
   nRet = L_Doc2ExportZonesExt(hDoc, nDocId, nPageIndex, pszZoneFile); 
   if (nRet == SUCCESS) 
      MessageBox(NULL, TEXT("Exports the zone list into a zone file."), TEXT("Notice!"), MB_OK); 
   else 
      return nRet; 
    
   return SUCCESS; 
} 
Help Version 20.0.2020.4.2
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2020 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS OCR Module - OmniPage Engine C API Help