"Darren Franklin" <[EMAIL PROTECTED]> wrote:
> I have an application that I want to revise and add more data to the records
> that already exist. How would you do this?
>
> My guess is that an updating function would need to be written which opens
> the old records 1 at a time, and copies the data to the new record
> structure, and adding appropriate defaults for the new data fields. But how
> would you do this if you had to save the data back into the same database?
I'm not sure, but I think the Date Book source code in the SDK might
prove helpful here. Create a new record using DmNewHandle, use DmWrite
to copy data from the existing record (plus whatever new data), then
use DmAttachRecord to attach this new record to the database at the
same index as the existing record. Then dispose of the old record
using MemHandleFree. The key is DmAttachRecord.
--
Roger Chaplin
<[EMAIL PROTECTED]>
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/