what is the datatype of Session

Posted by Packs under Interview Questions on 9/25/2012 | Points: 10 | Views : 1006 | Status : [Member] | Replies : 2
i n an interview i was asked
What is the data type of Session

and can we store dataset in sessions




Responses

Posted by: T.Saravanan on: 9/25/2012 [Member] [MVP] Silver | Points: 25

Up
0
Down
Session datatype is "Generic". So we store any type of data in "Session" object.

Ex:
I have stored datatable value in Session and get that value from session.

DataTable dtInput = new DataTable();
Session["Data"] = dtInput;
DataTable dtOutput = (DataTable)Session["Data"];


Thanks,
T.Saravanan

Packs, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Hariinakoti on: 9/25/2012 [Member] Starter | Points: 25

Up
0
Down
Nice Explanation Saravanan

Thanks & Regards
Hari

Packs, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response