Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > How to detect if user has close the browser?

Reply
Thread Tools

How to detect if user has close the browser?

 
 
Lord2702
Guest
Posts: n/a
 
      10-09-2004
Fri. Oct. 08, 2004 11:10 PM PT

In ASP.NET application, How to detect that user has close the browser, IE or
Netscape, or may be any other ?

Thanks,


 
Reply With Quote
 
 
 
 
Patrick.O.Ige
Guest
Posts: n/a
 
      10-09-2004
Use Javascript

"Lord2702" <(E-Mail Removed)> wrote in message
news:#(E-Mail Removed)...
> Fri. Oct. 08, 2004 11:10 PM PT
>
> In ASP.NET application, How to detect that user has close the browser, IE

or
> Netscape, or may be any other ?
>
> Thanks,
>
>



 
Reply With Quote
 
 
 
 
Lord2702
Guest
Posts: n/a
 
      10-09-2004
Hello Patrick,
I understand that it requires to use JavaScript, But Can you give some line
of code, How to do it? Thanks.

"Patrick.O.Ige" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Use Javascript
>
> "Lord2702" <(E-Mail Removed)> wrote in message
> news:#(E-Mail Removed)...
> > Fri. Oct. 08, 2004 11:10 PM PT
> >
> > In ASP.NET application, How to detect that user has close the browser,

IE
> or
> > Netscape, or may be any other ?
> >
> > Thanks,
> >
> >

>
>



 
Reply With Quote
 
RJN
Guest
Posts: n/a
 
      10-10-2004

The brwoser provides "onbeforeunload" event and you can use this in the
body tag to detect if the window is being closed


*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to close a TCP socket? (TCPSocket#close doesn't close it) IƱaki Baz Castillo Ruby 7 01-12-2010 01:32 PM
How to detect IE window close (X) action by user? =?Utf-8?B?S3VtYXIuQS5QLlA=?= ASP .Net 5 10-17-2007 10:43 AM
Browser close event (MSIE and FF): how to detect browser close ? pamelafluente@libero.it Javascript 0 01-23-2007 12:44 AM
How can I detect a user has clicked the X to close the Browser Window tarun.kataria@gmail.com ASP .Net 7 04-07-2006 04:27 AM
How to detect the user has logged out? Showjumper ASP .Net 1 01-27-2004 06:30 PM



Advertisments