session prob RRS feed

  • Question

  • User-478348433 posted

    hi all,
    iam new in this i really need help
    i want to creat a session  gives me information about the user who using my page
    like  "after 2 min without doing any thing in my asp.net page he will signout and need to signin again"
    i really dont know how to make this
    so plz f there is any one can help me

    Saturday, January 6, 2007 11:13 AM

All replies

  • User-891526991 posted


    Server will create a session if a client access the URL. In your case try to use this simple technique -  store userId or UserName i session variables

    If(login == success)

    Session["USERID"] = sUserID;

    In Page_Load method of every aspx page check this

    if(Session["USERID"] == null )

    Redirect user to Login page.  

    Hope this works. 



    Thursday, January 11, 2007 7:54 AM