|
QMExtract() |
|
|
The QMExtract() function extracts a field, value or subvalue from a dynamic array. It is analogous to the QMBasic field extraction operator or the EXTRACT() function.
Format
where
The QMExtract() function returns the given field, value or subvalue from the source string. If the required item is not found, a null string is returned.
Examples
The above program fragment reads the record identified by ClientNo from the file open as fClients and then extracts field 4 from it. A real program should test the ErrNo status from the read to determine if the action was successful.
Note that the C example leaves variables CliAddr pointing to a dynamically allocated memory area that must be released using QMFree() when no longer needed. |