How to extend session time out in ASP .NET 3.5 web application

Expert:
I have a dot net asp 3.5 C# web application that times out before a function loops through a  time consuming routine that generates and outputs a lot of word documents that are send to a printer for hard copies. Is there a way that the session time out period can be extended beyond normal session time or long enough to print all the documents? Or does the web server session time have to be extended to allow enough time to print all the documents. Please kindly tell me what can be done?
tcmmaxtAsked:
Who is Participating?
 
meetingexpectationsConnect With a Mentor Commented:
<configuration>
  <sessionstate
      mode="inproc"
      cookieless="false"
      timeout="20"
      sqlconnectionstring="data source=127.0.0.1;user id=<user id>;password=<password>"
      server="127.0.0.1"
      port="42424"
  />
</configuration>

Also check you IIS timeout..

http://support.yessoftware.com/kb_article.asp?kb_articlesPage=2&article_id=74
0
 
NishchayaAndrewConnect With a Mentor Commented:
hi tcmmaxt,

Session.Timeout = 60;//it means that you have extended the Session time out from default 20min to 60min.

I hope that above make sense & easy to alter/adopt, while if you go with the above it will set to all application by default. I believe that you shoud use this extended timje only when that page / process requires.

 
0
 
rajapandian_81Connect With a Mentor Commented:
In web.config file you can mention the timeout period in minutes.

<sessionState mode="InProc" cookieless="false" timeout="180"/>
0
All Courses

From novice to tech pro — start learning today.