Exiting IE Browser

Discussion in 'ASP General' started by fniles, Jan 2, 2008.

  1. fniles

    fniles Guest

    I am using classic ASP.
    Is there a way when a user close the IE browser for me to know and execute
    some ASP codes ?
    What I need is, when they close the IE browser, I would like to go to the
    database and modify some data there.
    In VB, there is Form_close event. Where in ASP I can put my codes when they
    exit the IE browser ?
    Thank you.
     
    fniles, Jan 2, 2008
    #1
    1. Advertising

  2. fniles wrote:
    > I am using classic ASP.
    > Is there a way when a user close the IE browser for me to know and
    > execute some ASP codes ?
    > What I need is, when they close the IE browser, I would like to go to
    > the database and modify some data there.
    > In VB, there is Form_close event. Where in ASP I can put my codes
    > when they exit the IE browser ?
    > Thank you.


    No there isn't. Sorry. You will need to use a scheduled task to do your
    cleanup. See
    http://classicasp.aspfaq.com/general/how-do-i-count-the-number-of-current-users/sessions.html
    --
    Microsoft MVP -- ASP/ASP.NET
    Please reply to the newsgroup. The email account listed in my From
    header is my spam trap, so I don't check it very often. You will get a
    quicker response by posting to the newsgroup.
     
    Bob Barrows [MVP], Jan 2, 2008
    #2
    1. Advertising

  3. fniles

    Guest

    Thank you.

    1. Can I put my clean up codes in the Session_OnEnd or
    Application_OnEnd in Global.asa ?
    2. In Session_OnEnd or Application_OnEnd, can I do Response.Redirect
    "anotherpage.asp" ?

    Thank you.

    On Jan 2, 4:22 pm, "Bob Barrows [MVP]" <>
    wrote:
    > fniles wrote:
    > > I am using classic ASP.
    > > Is there a way when a user close the IE browser for me to know and
    > > execute some ASP codes ?
    > > What I need is, when they close the IE browser, I would like to go to
    > > the database and modify some data there.
    > > In VB, there is Form_close event. Where in ASP I can put my codes
    > > when they exit the IE browser ?
    > > Thank you.

    >
    > No there isn't. Sorry. You will need to use a scheduled task to do your
    > cleanup. Seehttp://classicasp.aspfaq.com/general/how-do-i-count-the-number-of-cur...
    > --
    > Microsoft MVP -- ASP/ASP.NET
    > Please reply to the newsgroup. The email account listed in my From
    > header is my spam trap, so I don't check it very often. You will get a
    > quicker response by posting to the newsgroup.
     
    , Jan 3, 2008
    #3
  4. <> wrote in message
    news:...
    >
    >1. Can I put my clean up codes in the Session_OnEnd or
    >Application_OnEnd in Global.asa ?
    >2. In Session_OnEnd or Application_OnEnd, can I do Response.Redirect
    >"anotherpage.asp" ?


    I wouldn't trust either of these.

    Store a session expiry value in the database and have a scheduled task tidy
    up any session that has expired.

    Give the user a 'log out' option in your HTML so that there is an option to
    explicitly close things out. At the point navigate to a Logged out page (or
    the login/home page).

    --
    Anthony Jones - MVP ASP/ASP.NET
     
    Anthony Jones, Jan 3, 2008
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. jiten

    exiting from state machine

    jiten, Jun 22, 2005, in forum: VHDL
    Replies:
    3
    Views:
    505
  2. Anne
    Replies:
    0
    Views:
    378
  3. =?Utf-8?B?Qm9uag==?=

    problem with aspnet exiting

    =?Utf-8?B?Qm9uag==?=, Nov 11, 2004, in forum: ASP .Net
    Replies:
    3
    Views:
    349
  4. =?Utf-8?B?YmJkb2J1ZGR5?=

    Exiting an ASP.net application

    =?Utf-8?B?YmJkb2J1ZGR5?=, Jun 24, 2005, in forum: ASP .Net
    Replies:
    2
    Views:
    538
    samitha
    Sep 21, 2006
  5. BrainC
    Replies:
    8
    Views:
    2,238
    JustSomeGuy
    Sep 11, 2003
Loading...

Share This Page