Some basic principles I think I am missing/lacking!!!
1) When you hand a textTableItem a handle in the Load call back when/if does
the
field contained in the table free the handle. ( Assuming the Save
callback is not
implemented).
2) In a TableSaveDataFuncType ( only called if the user tapped and is
leaving the field)
Should you set the Fld Text handle to 0??
3) As all can see I am no expert!! If I have a table that has 4 rows 2 cols
each.
Col 0 is the lablel col. Col 1 is the col for the user to edit/create the
data.
If I load the table and the user never edits, the save callback never
happens.
Where does the clean up code go? Is this how must folks use tables
I have the following:
MemHandle gTextHandles[5]; <-- 5 mem handles to set in my custom Load
callback.
In the frmOpenEvent I allocate the handles
char *tempString;
for (I = 0, i<4 , i++)
{
gTextHandles[i]= MemHandleNew(20);
tempString = MemHandleLock(gTextHandles[i]);
StrCopy(tempString , "Some Text!");
MemHandleUnlock(gTextHandles[i]);
}
In the Load call back I assing the pointers to this global mem handles
In the frmCloseEvent I want to clean up
for (I = 0, i<4 , i++)
{
MemHandleFree(gTextHandles[i]);
}
But my app crashes [EMAIL PROTECTED]
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/support/forums/