Barnett, Phil R wrote: > Does the following code handle memory allocation correctly for > skipping through every record of a table? > > numRecs = DmNumRecords(gDB);
You might consider using DmNumRecordsInCategory, rather than DmNumRecords. numRecs = DmNumRecordsInCategory(gDB, dmAllCategories); DmNumRecords also counts records where the "deleted" bit has been set. I.e. records that have been deleted using DmDeleteRecord, rather than DmRemoveRecord. If you try to access deleted records you will most likely get a null handle. Regards -Laurens -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
