Here is the call stack:
FrmRemoveObject
- PrvMoveFormInternals
-PrvRewireForm
-PrvRewireForm
-PrvOffsetPtrIfNeeded // HAVING PROBLEMThanks, Jenni
----- Original Message ----- From: "Jennifer Fell" <[EMAIL PROTECTED]>
To: "Palm Developer Forum" <[EMAIL PROTECTED]>
Sent: Monday, October 25, 2004 3:08 PM
Subject: problems with FrmRemoveObject
Here is a piece of code which gets executed when removing a object that has a number of popup lists. These lists are dynamically created in that object's constructor function. Anyway, this FrmRemoveObject crashes in some specific situations. I know it's impossible to tell what's going on without looking at the codes, but still I wonder if anybody can guess what could possibly cause this problem. FYI,
for (i = TOTAL_LISTS - 1; i >= 0; i--) {
lstId = popupLists[i].lstId; objId = FrmGetObjectIndex (frmP, lstId); FrmHideObject (&frmP, objId); FrmRemoveObject (&frmP, objId); //CRASHES HERE
ctlId = popupLists[i].ctlId; objId = FrmGetObjectIndex (frmP, ctlId); FrmHideObject (&frmP, objId); FrmRemoveObject (&frmP, objId); }
Thanks, Jenni
Just in case you are curious about the construction process, here is a portion of the constructor function where I am creating the object (there mightbe some typo errors):
lastRsrcId = 2000; for (i = 0; i < TOTAL_LISTS; i++) {
if (!CtlNewControl ((void**)&frmP, ++lastRsrcId, popupTriggerCtl, NULL, 0, 0, maxWidth, 0, stdFont, NULL, true) { ErrDisplay ("Memory ERROR!"); return; } popupLists[i].ctlId = lastRsrcId;
if (LstNewList ((void**)&frmP, ++lastRsrcId,
0, 0, maxWidth, 0, stdFont, 3,
popupLists[i].popupBox[popupBox].ctlId)) {
ErrDisplay ("Memory ERROR!");
return;
}
popupLists[i].lstId = lastRsrcId;
}
--
For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
-- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
