version 2003
PA_GetDateField (tNum; fNum; day; month; year)
Parameter | Type | Description | |
tNum | short | Table number of the field to access | |
fNum | short | Field number of the field to access | |
day | short* | Pointer to the day of the date | |
month | short* | Pointer to the month of the date | |
year | short* | Pointer to the year of the date |
Description
The routine PA_GetDateField fills the shorts pointed to by day, month, year with the values of the date field number fNum of the current record of table number tNum.
If aVariable is not a eVK_Date variable, the routine does nothing and leaves *day, *month and *year unchanged.
day, month and day can be null pointer if you do not want to read those values.
Example
Check the year of a particular date.
short year = 0; PA_GetDateField( table, field, 0, 0, &year ); if ( year == 1961 ) { /* . . . */ }
See Also
Error Handling
Use PA_GetLastError to see if an error occurred (eER_InvalidFileNumber, eER_InvalidFieldNumber).