Hi all,
I am trying to use offsetof C Macro in DmWrite() and the compiler complains.
See error message below.
Error : expression syntax error
ChecklistDB.c line 43 DmWrite(s, offsetof(FacilityPacked, facility_id),
(char*) &facility->facility_id, sizeof(facility->facility_id) );
Error : expression syntax error
ChecklistDB.c line 44 DmStrCopy(s, offsetof(FacilityPacked, facility_name),
(char*) facility->facility_name);
It complains on FacilityPacked data structure. This is how it is defined in the
header file:
typedef struct {
UInt32 facility_id;
char facility_name[1];
} FacilityPacked;
Do I need to add any file to the Project Settings? Thanks.
-Elizabeth
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/