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

Is object a value type or referenced type?

2 Answers  


What method do you use to explicitly kill a users session?

2 Answers   Siebel Systems,


What are web server controls in asp.net?

0 Answers  


What ASP.NET object encapsulates the state of the client and the browser? a) The Session object b) The Application object c) The Response object d) The Request object e) The Server object

7 Answers   Bunzl Vending, Syntax Softtech,


What are the memory-mapped files?

0 Answers  






Describe paging in asp.net?

0 Answers  


How to send data through querystring to another page but it should not be displayed in URL

2 Answers   EMR, Powersoft19,


Types of state management techniques ?

6 Answers   Digital GlobalSoft,


What are the different types of cookies in asp.net?

0 Answers  


What is application variable and when it is initialized ?

4 Answers   Keane India Ltd,


can i use store procedure in disconnected mode? give me answer

2 Answers  


What is the use of location tag in web.config file

2 Answers   Karur Vysya Bank KVB,


Categories