Function _stords() Foundation

Assigns a character string as a date value to a parameter.

Syntax
BOOL _stords(CHAR* cDate,
             XppParamList pList, ULONG ulIndex, ...);
Parameters
CHAR *cDate
Pointer to a string which represents a date in the form "YYYYMMDD". Only the first 8 characters of the string will be regarded.
XppParamList pList
Pointer to the Xbase++ parameter list, which is used to provide access to the parameter.
ULONG ulIndex
Position of the parameter which is to be changed (first parameter is 1).
...
The remaining arguments are only considered when the parameter is an array. They must be of ULONG type. To select an element of the array an index is specified for each array dimension. If the array value itself should be replaced, NULL must be specified as the first value. Note:The end of the array index list must be indicated by incorporating a NULL as the last value in the list.
Return

Always returns TRUE.

Description

_stords() is used to return a date value. The string must contain a zero padded date in the form "YYYYMMDD". Any additional characters in the string are ignored. If the string can not be converted into a valid date, the parameter value is set to a NULL date.

This function is normally used along with parameters passed by reference to return multiple values to the calling function. However, the changed parameters can also be accessed again within the C function.

Examples
/* 
Assigns a date to a parameter 
*/ 
#include <xpppar.h> 

stords("19940726", <pList>, 1, 0); 

Feedback

If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.