Live Chat Icon For mobile
Live Chat Icon

How can I use Session variables in a class

Platform: ASP.NET| Category: Session

Use HttpContext.Current.Session

VB.NET


HttpContext.Current.Session('Value1') = '1'

C#


HttpContext.Current.Session['Value1'] = '1';

In similar manner you can use Application Variables too.

Share with

Share on twitter
Share on facebook
Share on linkedin

Related FAQs

Couldn't find the FAQs you're looking for?

Please submit your question and answer.