Skip to content

Instantly share code, notes, and snippets.

@rousso
Created October 22, 2012 17:00
Show Gist options
  • Save rousso/3932563 to your computer and use it in GitHub Desktop.
Save rousso/3932563 to your computer and use it in GitHub Desktop.
PageState: You can use PageState much like you use ViewState
SomeClass SomePoperty
{
get
{
return PageState["SOME_PROPERTY_NAME"] ??
(PageState["SOME_PROPERTY_NAME"] = default(SomeClass)) as SomeClass;
}
set
{
PageState["SOME_PROPERTY_NAME"] = value;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment