If you are getting session expired errors, you can either increase your session time, or use something like
this article suggests.[
^]
Another way would be to save your session state, either to a database or using cookies etc... it all depends what you are trying to achieve.