FmtSetField
Sets data in a field of a format template. After you have set all the fields, you can build the formatted string with the FmtToStr() function.
Syntax
FmtSetField(hFmt, Name, Data)
hFmt:
The format template handle, returned from the FmtOpen() function. The handle identifies the table where all data on the associated format template is stored.
Name:
The name of the format template.
Data:
Field data.
Return Value
0 (zero) if successful, otherwise an error is returned.
Related Functions
Example
hFmt=FmtOpen("MyFormat","{Name}{Desc, 20}",0);
FmtSetField(hFmt,"Name", "CV101");
FmtSetField(hFmt,"Desc","Raw Coal Conveyor");
Str =FmtToStr(hFmt);
! Str will contain "CV101 Raw Coal Conveyor".
See Also