TE Edit Control Win32 / Win64 Help
Product page

TerInsertField

Insert a data field.

BOOL TerInsertField(hWnd, name, data, repaint)
BOOL TerInsertFieldU(hWnd, name, UnicodeData, repaint)
HWND hWnd;The handle of the window to be accessed
LPBYTE name;Field name
LPBYTE data;Field data. Set to NULL to insert a field without field data. This parameter is used by the TerInsertField function only.
LPWORD UnicodeData;Field data in unicode format. Set to NULL to insert a field without field data. This parameter is used by the TerInsertFieldU function only.
BOOL repaint;TRUE to repaint the screen after the operation.

Description: This function inserts a field name and field data in the document. Please note that a data field is different from a mail merge field. A field inserted using this function can not be used for mail merge. Refer to 'Mail Merge Support' chapter for information about mail merge fields.

Return Value: This function returns TRUE when successful.