Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Control validating when user closing form
Message
From
07/07/2004 09:53:42
 
 
To
07/07/2004 01:30:32
General information
Forum:
ASP.NET
Category:
Forms
Miscellaneous
Thread ID:
00921300
Message ID:
00921377
Views:
11
>In a "validating" method that has been fired for a control, is there a way to detect that the user has clicked on the form's close button (the 'X'), so that validation can be bypassed?

Steve,

I looked through the various Form properties and couldn't find anything obvious.

But, I wonder if that's what you really want to do? Typically, when a user clicks on the 'X', they should be asked if they want to save their changes (if there are any, that is) and so I think your validations should still execute. A lot of users click on the 'X' not necessarily as a means of "escaping" the process, but just because it's an easy way to close a form and a lot do it out of habit. I'd hate for them to lose all changes to data on the form without informing them of such.

~~Bonnie
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform