Creates an item-list from the currently opened User dictionary together with the IG_REC_UD_item_next_get function.
Copy Code
|
|
---|---|
AT_ERRCOUNT ACCUAPI IG_REC_UD_item_first_get( LPCSTR pSection, LPWSTR pUDitem, AT_INT nBufferSize, enumIGRecUDItemAttribute* pitemattrib ); |
Name | Type | Description |
---|---|---|
pSection | LPCSTR | Name of the section of the User dictionary whose items are to be listed. |
pUDitem | LPWSTR | Pointer to a buffer to get the first UNICODE item of the item-list. |
nBufferSize | AT_INT | Specifies the size of the pUDitem buffer in bytes. It must be large enough to hold all the characters and the terminating zero. |
pitemattrib | enumIGRecUDItemAttribute* | Pointer to a variable to hold the item's attribute. |
This function does not process image pixels.
Copy Code
|
|
---|---|
AT_ERRCOUNT ErrCount = 0; AT_INT iSize = 1024; LPWSTR lpszFirst = (LPWSTR) malloc(iSize); enumIGRecUDItemAttribute eFormat = IG_REC_UD_ITEM_ATTR_LITERAL_STRING; ErrCount += IG_REC_UD_set("NEW_USER.DICT", "Section_A"); ErrCount += IG_REC_UD_edit_open(); ErrCount += IG_REC_UD_item_first_get("Section_A", lpszFirst, iSize, &eFormat); ErrCount += IG_REC_UD_edit_close(); free(lpszFirst); |
This function returns the first item (the UDitem and its attribute) from the pSection section of the User dictionary. The application has to allocate a buffer with sufficient size to accommodate the current UDitem.
Maximal length of the dictionary item is AM_MAX_UD_ITEM_LEN.