getting error in the following C++ code. how to fix it??? mentioned the error in the appropriate line below in which it appeared while compiling someone let me know.....
// PACK DATE INTO INTERNAL FORMAT
Dtime_t // Error: Dtime_t does not name a type
PckDat
{ int year;
int month;
int day;
long jd; // Julian day
int *dayTbl; // Pointer to ordtbl or leaptbl
double v; // Packed date value
// Ordinary and leap year offsets
static int FAR ordTbl[13] =
{0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365};
static int FAR leapTbl[13] =
{0, 31, 60, 91, 121, 152, 182, 213, 244, 274, 305, 335, 366};
if (year < 0 || year >= 3000) return NULL_TIME;
if (month < 1 || month > 12) return NULL_TIME;
//-----------------------------------------------------------------------------// TRANSLATE TIME INTO YEAR, MONTH, DAY, HOUR, MINUTE AND SECOND
void XltTime ( // Error: variable or field XltTime declared void
Dtime_t date // Error: DTime_t was not declared in this scope
{ int *year; // Year
int *month; // Month
int *day; // Day
int *hour; // Hour
int *min;) // Minutes
double x; // Temporary
long jd; // Julian day
long yr; // Offset year
int mth; // Internal month
long n400; // Number of 400 year periods
long n100; // Number of 100 year periods
long n4; // Number of 4 year periods
long n1; // Number of 1 year periods
// Ordinary and leap year offsets
static int FAR ordTbl[13] =
{0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365};
static int FAR leapTbl[13] =
{0, 31, 60, 91, 121, 152, 182, 213, 244, 274, 305, 335, 366};
int *dayTbl; // Pointer to ordtbl or leaptbl
// If the date is outside the acceptable range, return zeros