----------------------------------------------------------- New Message on BDOTNET
----------------------------------------------------------- From: Mrinal Message 7 in Discussion Hi San , There's no problem with santhecoolguy's solution , see what u need to do is after storing the value in viewstate for the first time , u need to re extract everytime when u need that value in your program , It can be done by explicitly typecasting the viewstate value for e.g : string tempValue = (string)ViewState["s"] ; // just an example basically viewstate is nothing but a container which can contain any value of any type but the whole decision of choosing session or viewstate depends upon design and internal working for e.g: viewstate is posted back from client to server during each postback so , it's normally not being preferred to have big values like dataset , similarly application or session objects are containers maintained at server , with some difference in working Now in ur case u can try by explicitly typecasting as shown above and it's sure it will work , for e.g: ViewState["s"] = "MyValue"; // Setting value initially Now in ur button click do following : if((string)ViewState["s"] = = "SomeValue") ViewState["s"] = " NewValue"; i hope it's clear or send me ur code i will post back the exact changes u need to get the things working , Regards , Mrinal ----------------------------------------------------------- To stop getting this e-mail, or change how often it arrives, go to your E-mail Settings. http://groups.msn.com/bdotnet/_emailsettings.msnw Need help? If you've forgotten your password, please go to Passport Member Services. http://groups.msn.com/_passportredir.msnw?ppmprop=help For other questions or feedback, go to our Contact Us page. http://groups.msn.com/contact If you do not want to receive future e-mail from this MSN group, or if you received this message by mistake, please click the "Remove" link below. On the pre-addressed e-mail message that opens, simply click "Send". Your e-mail address will be deleted from this group's mailing list. mailto:[EMAIL PROTECTED]
