I am facing problem in asp.net.
Problem is : Session objects is not working properly.in the sense some times it will work some times not(getting empty).
Plz Can anyone help me in this . Its very urgent !!!!!!
Eg:
In web.config - In <Sessionstate timeout=30>,but before 30 minutes only its getting empty.
2) In Global.asa : session_start - if i give session("emp_code"),
Whwn i login some times that session("emp_code") is getting empty.

Thank you for reply

Rooparaj K N

Recommended Answers

All 7 Replies

To my knowledge you have to set the Method of Storage for the session.

See: Link

You need to specify the session storage method:

So that is why ou are having an empty Session!

Hope this helps!

I am facing problem in asp.net.
Problem is : Session objects is not working properly.in the sense some times it will work some times not(getting empty).
Plz Can anyone help me in this . Its very urgent !!!!!!
Eg:
In web.config - In <Sessionstate timeout=30>,but before 30 minutes only its getting empty.
2) In Global.asa : session_start - if i give session("emp_code"),
Whwn i login some times that session("emp_code") is getting empty.

Thank you for reply

Rooparaj K N

hi Paladine
its praveen i want to ask u how can i store my customer id in any variable so i can access it in Query to get data form table then and then i want to use it in next or next page
2 when i use back button then it will run my load event from that particular id and return all information so user didn't get Error
can u halp me to do this

Ok I am sorry to say, but your question is framented, and a little vague.

The page_load event does not fire when you use the back button. This event only fires on a Refresh or first time to the page. Back button relies on the browser cache.

To retain the CustomerID for what ever purpose, I would just use a session variable.

Session_Start
Session("CustID") = 0

Then in the first query on the DB, you reassign the retrieved value to th Session object.

Not sure whatelse you are asking for?

hi Paladine
its praveen i want to ask u how can i store my customer id in any variable so i can access it in Query to get data form table then and then i want to use it in next or next page
2 when i use back button then it will run my load event from that particular id and return all information so user didn't get Error
can u halp me to do this

hi i want a user control to show me a popup calender and then i select a date and it comes in the text box as 24-mar-2005 is it possible if yes then give me link or code behind

hi is it possible to convert a access db int0o the xml, xsl, xslt files
i read it but forget it so i wnat to reopen it

The sentence kind of makes sense, but maybe you could take another stab at it and explain what you want to do exactly? And how that applies to session objects (the theme of this thread)?

You can convert the Access DB tables to XLS, HTML or ASP files, but not to xml or xsl/xslt files (to my knowledge not directly anyway).

hi is it possible to convert a access db int0o the xml, xsl, xslt files
i read it but forget it so i wnat to reopen it

If your problem is that your page is getting timed out before the timeout value set.
Then I will suggest you to change your web.config code like this.

<sessionState 
        mode="StateServer"
        cookieless="false" 
        timeout="30"/>

Here I have changed the session state to a seperate worker process (ASP state management server).

It is recommended to move your session into the stateserver or SQL server state management in the production environment.

Note: You need to start the 'ASP.NET State Service' windows service on the web server in order to make this code work.

I am facing problem in asp.net.
Problem is : Session objects is not working properly.in the sense some times it will work some times not(getting empty).
Plz Can anyone help me in this . Its very urgent !!!!!!
Eg:
In web.config - In <Sessionstate timeout=30>,but before 30 minutes only its getting empty.
2) In Global.asa : session_start - if i give session("emp_code"),
Whwn i login some times that session("emp_code") is getting empty.

Thank you for reply

Rooparaj K N

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.