SessionState - type of sessionstate and when and how to use
it



SessionState - type of sessionstate and when and how to use it..

Answer / alb.shah

SessionState tag is used to define session attributes.
One very important is Mode which can have values: "state
server", "SqlServer", "InProc"; depending how you want to
preserve session state.
"State server" is used if you want the state to be
preserved in other server.
"SqlServer" is used if you want the state to be preserved
on a SQL database.
"InProc" is used if you want the state to be preserved in
the same process where the asp.net page is running.

Other attributes that are also included for the
SessionState tag are: ConnectionString,
SqLConnectionString, userId, password, cookiless, tiemout.

if the session state is going to be preserved in other
server, or can be ""SqlServer" if session state is going to
be preserved in a SQL database

Configuring session state: Session state features can be
configured via the <sessionState> section in a web.config
file. To double the default timeout of 20 minutes, you can
add the following to the web.config file of an application:
<sessionState
timeout="40"
/>

Is This Answer Correct ?    3 Yes 0 No

Post New Answer

More ASP.NET Interview Questions

Explain the difference between debug.write and trace.write? When should each be used?

0 Answers  


How do you validate the controls in an ASP .NET page?

3 Answers  


About Postback ?

6 Answers   Accenture,


How does the XmlSerializer work? What ACL permissions does a process using it require?

2 Answers  


Explain security types in asp.net?

0 Answers  






Way of updating a table other than stored procedure and hard coded query?

2 Answers  


What is server transfer?

0 Answers  


What is asp.net localization?

0 Answers  


When does a session actually start?

0 Answers  


Can the action attribute of a server-side tag be set to a value and if not how can you possibly pass data from a form page to a subsequent page?

1 Answers  


Does C# support static class?Is Static class be inherited by any class?

2 Answers  


What is different authentication mechanisms used in ASP.NET?

0 Answers   Amdocs,


Categories