PDA

Click to See Complete Forum and Search --> : Server.Transfer, not autofilling controls from viewstate


MetallicaD
Feb 15th, 2004, 01:05 PM
Hey all.. i am doing a server.transfer from 1 page to another, i have EnableViewStateMAC set to true, and i want the fields on the second page with matching names (IDs) from the first page to get populated with the values from the first page... on the secondpage, i do not get any errors and I CAN step through the request.forms collection and see the data from the first page just fine (woo hoo!), but for some reason, the controls are not getting populated. I would prefer to not have to do this manually.

Any thoughts on why they arent getting populated from the values on the first page???

Another clue.. I am actually transfering from the same page as the one I am transfering too... you wonder why? its because I am doing this in the onError event.. if the server.getlasterror() is of a certian type that I have defined, I want to cancel the error and return control back to my page, displaying a specific message... if there is an easier way to transfer control after canceling the error, im all ears, but id like to be able to maintain the view state.

Any thoughts?

Thanks,
-md