Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Session

Session

Scheduled Pinned Locked Moved ASP.NET
csharpasp-netquestion
6 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    Socheat Net
    wrote on last edited by
    #1

    I have asp.net page for user login, after login they can sign out before exit page, but if they not click logout, the machine will remember his/her ID? ................

    A 1 Reply Last reply
    0
    • S Socheat Net

      I have asp.net page for user login, after login they can sign out before exit page, but if they not click logout, the machine will remember his/her ID? ................

      A Offline
      A Offline
      alyeasad
      wrote on last edited by
      #2

      At the LOGIN save the user id in session e.g Session["UserId"] = userid.Text and on button click of logout clear the Session value. What will happen is if he doesnt press the logout button the value stays stored otherwise it will be cleared. So u can use this value the next time he/she logs in. Hope I helped If only they could see what I see in my mind

      S 1 Reply Last reply
      0
      • A alyeasad

        At the LOGIN save the user id in session e.g Session["UserId"] = userid.Text and on button click of logout clear the Session value. What will happen is if he doesnt press the logout button the value stays stored otherwise it will be cleared. So u can use this value the next time he/she logs in. Hope I helped If only they could see what I see in my mind

        S Offline
        S Offline
        Socheat Net
        wrote on last edited by
        #3

        I still can not get it, i mean if he does not click button logout, when other user open web as computer is will dispaly old user ................

        R 1 Reply Last reply
        0
        • S Socheat Net

          I still can not get it, i mean if he does not click button logout, when other user open web as computer is will dispaly old user ................

          R Offline
          R Offline
          RedhaDev
          wrote on last edited by
          #4

          The server will close automatically any session after 20 minutes of inaticity. you can modify this parameter (20 min) in your Web.config file. or by using the command "Session.timeout = 44;" (44 minutes for exp). To clear all Session variables => "Session.Clear();" Regards The novice.

          S 1 Reply Last reply
          0
          • R RedhaDev

            The server will close automatically any session after 20 minutes of inaticity. you can modify this parameter (20 min) in your Web.config file. or by using the command "Session.timeout = 44;" (44 minutes for exp). To clear all Session variables => "Session.Clear();" Regards The novice.

            S Offline
            S Offline
            Socheat Net
            wrote on last edited by
            #5

            Thank for for helped me. ................

            A 1 Reply Last reply
            0
            • S Socheat Net

              Thank for for helped me. ................

              A Offline
              A Offline
              alyeasad
              wrote on last edited by
              #6

              Sorry I didnt understand the problem if what novice said helped u then I misinterpreted ur prob If only they could see what I see in my mind

              1 Reply Last reply
              0
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • World
              • Users
              • Groups