Home All Groups Group Topic Archive Search About
Author
12 Jun 2005 6:29 PM
huseyin_akturk
Hi,
I have a web application using C#.  In my application, I am creating a process.  This process can be progresses several minutes.  But I need that when user clicks close button(X), that process should be killed. So, I think that I have to catch the event when user clicks close button.  How can I do? -- huseyin_akturk ------------------------------------------------------------------------ Posted via http://www.codecomments.com ------------------------------------------------------------------------

Author
12 Jun 2005 9:40 PM
Scott M.
If the user closes their browser, only the browser knows about it.  You are
asking about the page closing event, but that's not what's happening.  It is
the client-side onClose() event handler that you need to be writing code
for.


Show quoteHide quote
"huseyin_akturk" <huseyin_akturk.1qj***@mail.codecomments.com> wrote in
message news:huseyin_akturk.1qj75n@mail.codecomments.com...
>
> Hi,
> I have a web application using C#.  In my application, I am creating a
> process.  This process can be progresses several minutes.  But I need
> that when user clicks close button(X), that process should be killed.
> So, I think that I have to catch the event when user clicks close
> button.  How can I do?
>
>
>
> --
> huseyin_akturk
> ------------------------------------------------------------------------
> Posted via http://www.codecomments.com
> ------------------------------------------------------------------------
>
Author
13 Jun 2005 6:21 PM
Mythran
Show quote Hide quote
"Scott M." <s-mar@nospam.nospam> wrote in message
news:egxcWe5bFHA.796@TK2MSFTNGP09.phx.gbl...
> If the user closes their browser, only the browser knows about it.  You
> are asking about the page closing event, but that's not what's happening.
> It is the client-side onClose() event handler that you need to be writing
> code for.
>
>
> "huseyin_akturk" <huseyin_akturk.1qj***@mail.codecomments.com> wrote in
> message news:huseyin_akturk.1qj75n@mail.codecomments.com...
>>
>> Hi,
>> I have a web application using C#.  In my application, I am creating a
>> process.  This process can be progresses several minutes.  But I need
>> that when user clicks close button(X), that process should be killed.
>> So, I think that I have to catch the event when user clicks close
>> button.  How can I do?
>>
>>
>>
>> --
>> huseyin_akturk
>> ------------------------------------------------------------------------
>> Posted via http://www.codecomments.com
>> ------------------------------------------------------------------------
>>
>
>

If you are performing a process on the server and want to check to see if
the client is still open you can use Response.IsClientConnected.

HTH :)

Mythran