How to set the time limit for a Page

Discussion in 'C#' started by Ridder, Jun 22, 2009.

  1. #1
    Dear all,

    How to set the time limit of a page as 10 minutes.

    That is if the screen is idle for 10 minutes then I need to throw an message like "Your session has been expired due to the screen is idle for long time" and the corresponding page have to be expired.

    Can you please anyone help me to solve this and thanks in advance.
     
    Ridder, Jun 22, 2009 IP
  2. dopanel.com

    dopanel.com Peon

    Messages:
    93
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #2
    You can using a javascript to control this
     
    dopanel.com, Jun 24, 2009 IP
  3. DoDo Me

    DoDo Me Peon

    Messages:
    2,257
    Likes Received:
    27
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Timeout
    The Timeout property specifies the timeout period assigned to the Session object for this application, in minutes. If the user does not refresh or request a page within the timeout period, the session ends.

    Syntax
    Session.Timeout [ = nMinutes]

    Parameters
    nMinutes
    Specifies the number of minutes that a session can remain idle before the server terminates it automatically. The default is 20 minutes.
    Applies To
    Session Object
     
    DoDo Me, Jun 24, 2009 IP
  4. zain654321

    zain654321 Peon

    Messages:
    202
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    You can use the ASP Session Object to set a timeout for the page.
    www.w3Schools.com reference
     
    zain654321, Jul 8, 2009 IP
  5. DoDo Me

    DoDo Me Peon

    Messages:
    2,257
    Likes Received:
    27
    Best Answers:
    0
    Trophy Points:
    0
    #5
    He need a message displayed on user's page, so have to use client script, like JavaScript
     
    DoDo Me, Jul 8, 2009 IP