Variables and ASP.NET
Posted on 2005-04-13
I need to add a new user to my ASP.NET application. This process is done filling three Forms (UserControls). When i validate the first form, I create a new object CadUser, that stores all user information and roles that is being filled by the forms.
Suppose that i ended filling my first form. So, i click on my NextStep button. When I Click on it, a new CadUser object is created (It is created as as "Class Level" object, not as "Method Level") and i redirected to the 2nd form. So, i fill the 2nd form. When i will store the information filled on the 2nd form, i try to get a reference to the CadUser obj created before, and it is not there... (CadUser = Nothing)
So, i need to know how i could store objects that will be read after a page postback and how could i dispose the resources used by this object when i don't need to use it anymore.