Click here to Skip to main content
15,892,517 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I have bound Dropdown and it works perfectly; now i want to write an event while changing selected index of the dropdown. I have set autopostback property of thae dropdown True.
But while changing the index of the dropdown page loads and dropdown displays the previous value.

Can anyone suggest me how to solve this.

Thanks in advance.
Posted
Comments
manognya kota 10-Sep-12 5:24am    
Where are you setting the autopost back property? i mean in server side method or client side method?
sahabiswarup 10-Sep-12 5:26am    
in client side
Tejas Vaishnav 10-Sep-12 6:35am    
place your code for dropdown binding in NOT IsPostback. then try.
i think this will cause because each and every time you post back using selected index change and it will re-bind your dropdown so your selected value will dis-appear.
Ashraff Ali Wahab 10-Sep-12 19:47pm    
Please post your code.Like Tejas said you might not be checking for IsPostback property and rebinding the Dropdown control without setting the selected index back.

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