You can't disable the X button without making the page fullscreen, and even
then they can alt+F4 or ctrl+W the page.
You can't keep them from closing the page, but you can warn them with a
client script
<script for=window event=onbeforeu nload language=javasc ript>
if(!YourValidat ion)
event.returnVal ue="Your Warning";
</script>
This will pop up a dialog warning them they are navigating away from the
page because of some reason, but you can't keep them from closing a page.
"Mike Nooney" <ju***@worldnet .att.net> wrote in message
news:oN******** **************@ bgtnsc05-news.ops.worldn et.att.net...
How do I disable the "X" in the upper right hand corner of my Web Page.
This is not for a windows form, but rather a web application. What I
really need is to stop the user from unloading the page, if certain data is not
present on the page. I know I should not use the Page_Unload event for
this. I wouild like to disable the Close Button, or putting some extra
validation behind a certain event, which event I am not sure. Any help
would be appreciated?