Home All Groups Group Topic Archive Search About
Author
27 Jul 2006 1:27 AM
HockeyFan
I'm somewhat new to .Net.  I have a dictionary object that I've been putting
keys and values into.  Is there a way to keep this around after a postback,
and if so, can someone point me to some code that does it.

Author
27 Jul 2006 2:36 AM
Ken Tucker [MVP]
Hi,

        Store it in session state

To store it
Session("MyDictionary")=MyDictionary

To retrieve it
if not Session("MyDictionary") is nothing then
Mydictionary=session("MyDictionary")
else
' your code goes here
end if

Ken
----------------------
Show quoteHide quote
"HockeyFan" <Hockey***@discussions.microsoft.com> wrote in message
news:83293FCB-3C08-41D6-A45F-F0D85721BB00@microsoft.com...
> I'm somewhat new to .Net.  I have a dictionary object that I've been
> putting
> keys and values into.  Is there a way to keep this around after a
> postback,
> and if so, can someone point me to some code that does it.
>