Click here to Skip to main content
15,886,518 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi All,

i am working on a classic asp application.It has more than 30 fields.I have added a cascading dropdown functionality in that page.But changes in dropdown list causes the selected values to be lost after postback.How can this issue be fixed?

<input name="LDAsset" size="20" readonly tabindex="36" enableviewstate="true">

Why doesnt adding enableviewstate="true" fix this?

Please help
Posted
Comments
F-ES Sitecore 22-Sep-15 6:56am    
As stated below, you need to read the selected values from the Request.Form collection and set the relevant "option" as being selected. Note that as there is no automatic state management in classic asp you'll need to re-build all the relevant options for each box too, they won't be remembered for you.

1 solution

Hi,

ViewState is a feature of ASP.NET, and was/is not available in classic asp.

In classic asp, you must manually maintain state, usually by retrieving form element values from the request.form collection.

... hope it helps.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900