Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
This can not be done! I give up :(
Message
From
30/06/2005 18:59:55
 
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP SP2
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01027858
Message ID:
01027956
Views:
15
>>Similar to the what others had posted.
>>
>>Create a property to store the last page deactivated (initialize to your start page). In the Deactivate, set the new property to your current page. In the Activate, check if the last page deactivated equals the current page. If it is, do nothing, else do your check for changes.
>>
>>You can get really fancy with this if you want it to look like it's remaining in the page you're trying to leave by using thisform.LockScreen, but that may not be worth the effort. You'd have to do lots of manipulating the ActivePage in order for it to look "right".
>
>In other words, you're proposing to move this code into Activate event. We have it working already with all of this, but it doesn't look right to me. Why should we use Activate event and go back to the prev. page (if we answer Cancel), if this functionality really belongs to Deactivate?

I agree it belongs in the Deactivate. I don't remember if we had just decided that it was No Big Deal if it prompted to save the changes or not, or if we had even noticed the problem in clicking on the same page. < shrug >

Like I said, you could hide the fact that you've switched pages by setting the LockScreen in the Deactivate and resetting it and playing with the ActivePage in the Activate. I don't see any other way as nothing else let's you know where you're trying to go in the Deactivate.
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform