L_Doc2GetUserDictionarySectionItem

NOTE: User words and dictionaries are no longer supported in the OCR Professional Engine.

#include "ltdoc2.h"

L_LTDOC2_API L_INT EXT_FUNCTION L_Doc2GetUserDictionarySectionItem(hDoc, pSection, pItem, nSize, puMask, bFirst)

L_HDOC2 hDoc;

handle to the OCR document

L_CHAR * pSection;

string containing the section name

L_WCHAR * pItem;

pointer to be updated

L_INT nSize;

buffer size

L_UINT32 * puMask;

pointer to be updated

L_BOOL bFirst;

flag

Gets section items from the specified section of the User dictionary.

Parameter Description
hDoc Handle to the OCR document.
pSection Name of the section of the User dictionary whose items are to be listed.
pItem Pointer to a buffer to get the first UNICODE item of the item-list.
nSize Size in bytes, of the buffer in bytes.
puMask Pointer to a variable to hold a value, which indicates which User dictionary to use.  Possible values are:
  Value Meaning
  DOC2_USER_DICT_LITERAL [0x0000] Used literal. This is the default value.
  DOC2_USER_DICT_REGULAR_EXPRESSION [0x0001] Used regular expression
bFirst Flag specifying which item to get. Possible values are:
  Value Meaning
  TRUE Get the first section item in the specified section
  FALSE Get the next section item in the specified section

Returns

SUCCESS

The function was successful.

< 1

An error occurred. Refer to Return Codes.

Comments

This function returns the item from the pSection section of the User dictionary.

Before calling this function, you must allocate a buffer with sufficient size to accommodate the current pItem parameter.

Call this function multiple times to get each of the items in a User dictionary section. The first time you call it, pass TRUE for bFirst. In each subsequent call, pass FALSE for bFirst, and LEADTOOLS will get the next item from the specified section. To re-start the process, call this function again, and pass TRUE for bFirst.

Required DLLs and Libraries

LTDOC2

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application.

Help Version 19.0.2017.10.27
Products | Support | Contact Us | Copyright Notices
© 1991-2017 LEAD Technologies, Inc. All Rights Reserved.
LEADTOOLS Professional OCR C API Help