Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
KmoverObj Problem when upgrading from 2.07 to 3.01
Message
General information
Forum:
Visual FoxPro
Category:
The Mere Mortals Framework
Miscellaneous
Thread ID:
00091187
Message ID:
00091220
Views:
20
Tom,

>I have a cbizobjmaintenanceform based form that is stable and function nicely under Codebook for Mere Mortals 2.07. I am trying to upgrade it to version 3.01 of Mere Mortals. When on page 3 and using a Kmoverobj I delete an item form the right side (the selectlist side) and then press the cancel button. Following that I get in a loop asking me "Do you want to save your changes first?". I cannot assure you that it is infinite, merely that it happens at least ten times. This does not happen with 2.07.>
>Ideas?

Here's the problem...Between version 2.07 and version 3.01, the MESSAGEBOX() call in CBizObjForm.AskToSave() was changed to an INTL MsgSvc() call. When control returns from a MESSAGEBOX, the Activate of the page is NOT re-executed. However, when control is returned from INTL's MsgSvc() the page Activate IS re-executed leading to the endless loop you are experiencing.

Here's a temporary fix for now:

In CBizObjForm.AskToSave()

Change...
***************************
IF This.lAllowSave

lcReply = MsgSvc('SaveChanges')

DO CASE
CASE lcReply = ccYES
lnAnswer = IDYES
CASE lcReply = ccNO
lnAnswer = IDNO
CASE lcReply = ccCANCEL
lnAnswer = IDCANCEL
ENDCASE
ELSE
lnAnswer = IDNO
ENDIF
***************************

To...
***************************
IF This.lAllowSave
lnAnswer = MESSAGEBOX('Do you want to save your changes first?',3+32,'Application Message')
ELSE
lnAnswer = IDNO
ENDIF
***************************

I will let you know when I have a permanent fix for this problem that works with INTL's MsgSvc().

Regards,
Kevin McNeish
Eight-Time .NET MVP
VFP and iOS Author, Speaker & Trainer
Oak Leaf Enterprises, Inc.
Chief Architect, MM Framework
http://www.oakleafsd.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform