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 related issues.

session related issues.

Scheduled Pinned Locked Moved ASP.NET
testingbeta-testing
12 Posts 2 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.
  • U Offline
    U Offline
    User 11886269
    wrote on last edited by
    #1

    when am accessing my application starting from login page to three more pages then session timeout resets for each pages...does session timeout reset for each page at the time of navigation from one page to other...if so the how can session time be retained for a single user until he is done with his operation. just for testing i put session timeout to 1 but when m navigating from one page to other time is resetting...i.e for each page it starts from 1 itself ...but i want it to start from the time that it has left in prev page for next page and so on.Please suggest me how could it be done. Thanks

    F 1 Reply Last reply
    0
    • U User 11886269

      when am accessing my application starting from login page to three more pages then session timeout resets for each pages...does session timeout reset for each page at the time of navigation from one page to other...if so the how can session time be retained for a single user until he is done with his operation. just for testing i put session timeout to 1 but when m navigating from one page to other time is resetting...i.e for each page it starts from 1 itself ...but i want it to start from the time that it has left in prev page for next page and so on.Please suggest me how could it be done. Thanks

      F Offline
      F Offline
      F ES Sitecore
      wrote on last edited by
      #2

      The session timeout resets with each request, that is how asp.net works. All you can do is increase the timeout if it isn't enough for you, but you can only increase it by so much and even then there is no guarantee your session won't be recycled by IIS. You should write your site in such a way that it gracefully survives session timeouts.

      U 1 Reply Last reply
      0
      • F F ES Sitecore

        The session timeout resets with each request, that is how asp.net works. All you can do is increase the timeout if it isn't enough for you, but you can only increase it by so much and even then there is no guarantee your session won't be recycled by IIS. You should write your site in such a way that it gracefully survives session timeouts.

        U Offline
        U Offline
        User 11886269
        wrote on last edited by
        #3

        Thanks for the response is their any alternate way to retain session time out for each page in asp.net

        F 1 Reply Last reply
        0
        • U User 11886269

          Thanks for the response is their any alternate way to retain session time out for each page in asp.net

          F Offline
          F Offline
          F ES Sitecore
          wrote on last edited by
          #4

          Not really, IIS manages your sessions for you, all you can do is give a suggested timeout.

          U 1 Reply Last reply
          0
          • F F ES Sitecore

            Not really, IIS manages your sessions for you, all you can do is give a suggested timeout.

            U Offline
            U Offline
            User 11886269
            wrote on last edited by
            #5

            Thank you..one more doubt can v provide different user different session time out or it will be managed by asp.net itself...since i have a requirement of booking an appointment online in this way how can be session managed for multiple no of users...

            F 1 Reply Last reply
            0
            • U User 11886269

              Thank you..one more doubt can v provide different user different session time out or it will be managed by asp.net itself...since i have a requirement of booking an appointment online in this way how can be session managed for multiple no of users...

              F Offline
              F Offline
              F ES Sitecore
              wrote on last edited by
              #6

              The session timeout in the config applies to all users, but if you want to change it on a per-user bases then you can set the timeout in the code using Session.Timeout and that will change the timeout just for that user.

              U 2 Replies Last reply
              0
              • F F ES Sitecore

                The session timeout in the config applies to all users, but if you want to change it on a per-user bases then you can set the timeout in the code using Session.Timeout and that will change the timeout just for that user.

                U Offline
                U Offline
                User 11886269
                wrote on last edited by
                #7

                Actually m talking according to the requirement as it happens in any booking site if one user has booked a slot then other user should be seen it as red mark which implies as its booked.at the time of his log in to the sites...in this way session value should be managed automatically for different user ....on the whole how can such requirement be done in asp.net..please help me out of this. Thanks

                1 Reply Last reply
                0
                • F F ES Sitecore

                  The session timeout in the config applies to all users, but if you want to change it on a per-user bases then you can set the timeout in the code using Session.Timeout and that will change the timeout just for that user.

                  U Offline
                  U Offline
                  User 11886269
                  wrote on last edited by
                  #8

                  is there anyway to activate session on button click ...that means as i click button session should start for specified period of time.not on page load. Thanks

                  F 1 Reply Last reply
                  0
                  • U User 11886269

                    is there anyway to activate session on button click ...that means as i click button session should start for specified period of time.not on page load. Thanks

                    F Offline
                    F Offline
                    F ES Sitecore
                    wrote on last edited by
                    #9

                    It sounds like using the Session isn't the best solution for whatever it is you're looking to do. Look at things like Cache to store data as that gives you more control over how long things stay valid for. You can specify explicit and sliding expiration.

                    U 1 Reply Last reply
                    0
                    • F F ES Sitecore

                      It sounds like using the Session isn't the best solution for whatever it is you're looking to do. Look at things like Cache to store data as that gives you more control over how long things stay valid for. You can specify explicit and sliding expiration.

                      U Offline
                      U Offline
                      User 11886269
                      wrote on last edited by
                      #10

                      thanks for the response now please read my requirement and provide best possible solution...if user is booking any slot then at the time of he booking slot to some specified time which is to be given.. till that time only he could book the slot otherwise session will get expire..and at the time of he booking slot if other user also logged in n booking the same slot that prev user is booking then for new user it should be shown as booked or slot is not available .

                      F 1 Reply Last reply
                      0
                      • U User 11886269

                        thanks for the response now please read my requirement and provide best possible solution...if user is booking any slot then at the time of he booking slot to some specified time which is to be given.. till that time only he could book the slot otherwise session will get expire..and at the time of he booking slot if other user also logged in n booking the same slot that prev user is booking then for new user it should be shown as booked or slot is not available .

                        F Offline
                        F Offline
                        F ES Sitecore
                        wrote on last edited by
                        #11

                        You're using confusing terminology, when you talk about Sessions people think you mean asp.net Sessions, you mean something completely different.

                        U 1 Reply Last reply
                        0
                        • F F ES Sitecore

                          You're using confusing terminology, when you talk about Sessions people think you mean asp.net Sessions, you mean something completely different.

                          U Offline
                          U Offline
                          User 11886269
                          wrote on last edited by
                          #12

                          sorry for the inconvenience but did you get my requirement...does my requirement require session concept ...how could i achieve it ..please help. Thanks

                          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