473,403 Members | 2,183 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,403 software developers and data experts.

Catching the closing browser event in the server side...

Is anyway I can catch the event of client closing the browser in server side
(ASP.Net) ???

Thanks in advance,
Genc Ymeri.
Apr 12 '06 #1
5 1190
The only way I know of is to use an AJAX method attached to the
window.unload event.

HTH,
Darren Kopp
http://blog.secudocs.com/

"genc ymeri" <ge********@hotmail.com> wrote in message
news:%2****************@TK2MSFTNGP04.phx.gbl...
Is anyway I can catch the event of client closing the browser in server
side (ASP.Net) ???

Thanks in advance,
Genc Ymeri.


Apr 12 '06 #2
The only way I know of is to use an AJAX method attached to the
window.unload event.
I second this thought.

Apr 12 '06 #3
There is absolutely no way to guarantee that this will work. Its better to
do work associated with a user leaving the webpage in the session_end event
handler of global.asax.

"cmay" wrote:
The only way I know of is to use an AJAX method attached to the
window.unload event.
I second this thought.

Apr 13 '06 #4
> There is absolutely no way to guarantee that this will work...
Tthat's what I was questioning too....


"William Sullivan" <Wi*************@discussions.microsoft.com> wrote in
message news:F1**********************************@microsof t.com...
There is absolutely no way to guarantee that this will work. Its better
to
do work associated with a user leaving the webpage in the session_end
event
handler of global.asax.

"cmay" wrote:
The only way I know of is to use an AJAX method attached to the
window.unload event.
I second this thought.

Apr 13 '06 #5
Oh yea, there is definately no way to guarantee that you will catch
this event.

What if the browser crashs? What if the person has javascript turned
off?

What I meant is that doing the AJAX method is the only way you can even
try to get this event. How often will it work? 70-80-90%? Who knows.
But if it something that you NEED 100% on, then you are out of luck.

Apr 13 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Wortelvisje | last post by:
Hello, What I want to do is quit simple: if the does clicks on the cross at the right top of the screen I want to catch this event and check a few things before closing the window. The only...
11
by: hawkon | last post by:
Hi all, I have an important question to ask about how to trap events when the user close the browser window. I'm a ASP programmer and I have s MSSQL database with a user table where I'm able to...
5
by: Ron L | last post by:
I have an MDI application with a number of child windows. In each child window I am catching the Closing event and having the child window decide if it should set cancel to true. The intent here...
3
by: Denon | last post by:
How to trap browser close event in SERVER side? I read a lot of forum message, it talk about onclose(), onunload() and even onbeforeunload() event. However, all of theses are based on javascript...
1
by: Chirag Malvi | last post by:
hello all, I am developing the web application using ASP.net and VS.2003 IDE. here is the situation which i want to implement. 1) User is browsing some webform. I want to trap this event....
5
by: Uma Muthu | last post by:
Hello Everyone, How can I capture the event of closing the IE browser from within an ASP.NET web application? TIA, Uma
3
by: bbdobuddy | last post by:
Hi, Is there any event that I can override to capture when a .aspx form closes? Regards bbdobuddy
7
by: Santel | last post by:
Hi, I would like to do some server side actions while closing the browser window. I tried with Page_Unload event, but it triggers while loading the page itself. Anyone please tell me is there...
1
by: George | last post by:
Hi. I have the following problem. I have an aspx page that a user earns points by playing a flash game. The flash program can write to session the points so the page knows every moment the points...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.