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 Timeout is not working

Session Timeout is not working

Scheduled Pinned Locked Moved ASP.NET
7 Posts 7 Posters 2 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.
  • E Offline
    E Offline
    Elena2006
    wrote on last edited by
    #1

    Hi, I have written in web.config for SessionTimeOut, but it is not working. It is always taking previous session even if after logout. Thanks in Advance

    T M A M P 6 Replies Last reply
    0
    • E Elena2006

      Hi, I have written in web.config for SessionTimeOut, but it is not working. It is always taking previous session even if after logout. Thanks in Advance

      T Offline
      T Offline
      thatraja
      wrote on last edited by
      #2

      You should have posted the code/web.config part in your question. For your information, check the answers in the below link Session time out automatically in asp.net web application[^]

      thatraja


      **My Tip/Tricks
      My Dad had a Heart Attack on this day so don't...
      **

      1 Reply Last reply
      0
      • E Elena2006

        Hi, I have written in web.config for SessionTimeOut, but it is not working. It is always taking previous session even if after logout. Thanks in Advance

        M Offline
        M Offline
        meeram395
        wrote on last edited by
        #3

        Try clearing the session while logging out.

        Success is the good fortune that comes from aspiration, desperation, perspiration and inspiration.

        1 Reply Last reply
        0
        • E Elena2006

          Hi, I have written in web.config for SessionTimeOut, but it is not working. It is always taking previous session even if after logout. Thanks in Advance

          A Offline
          A Offline
          Abhijit Jana
          wrote on last edited by
          #4

          Elena2006 wrote:

          . It is always taking previous session even if after logout.

          What code have you written during Log out. Try Session.Abandon() during logout. and in page load, you need to check the session value for null or not. If you are using Browser back / forward button to navigate you have to clear the cache from there.

          Cheers ! Abhijit Jana | My Blog | @Twitter | Daily .Net Tips

          1 Reply Last reply
          0
          • E Elena2006

            Hi, I have written in web.config for SessionTimeOut, but it is not working. It is always taking previous session even if after logout. Thanks in Advance

            M Offline
            M Offline
            Manoranjan Sahoo
            wrote on last edited by
            #5

            Use Session.Abandon() method to clear session. write below code on your logout button's click method : Session.Abandon(); Response.Redirect("default.aspx",false);

            Manoranjan Sahoo View My Site

            1 Reply Last reply
            0
            • E Elena2006

              Hi, I have written in web.config for SessionTimeOut, but it is not working. It is always taking previous session even if after logout. Thanks in Advance

              P Offline
              P Offline
              Prasanta_Prince
              wrote on last edited by
              #6

              Session.Abandon(); Response.Redirect("Default.Aspx"); This can workj for you.

              1 Reply Last reply
              0
              • E Elena2006

                Hi, I have written in web.config for SessionTimeOut, but it is not working. It is always taking previous session even if after logout. Thanks in Advance

                R Offline
                R Offline
                Ravi Sant
                wrote on last edited by
                #7

                use Session.Abandon();

                // ♫ 99 little bugs in the code, // 99 bugs in the code // We fix a bug, compile it again // 101 little bugs in the code ♫

                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