Based on your description and code provided, I see that if the dropdownlist selected item is not the initial item, once page post back, event
SelectedIndexChanged will be fired. As we know that if ViewState is disabled on the page or on the DropDownList control, the selected index
cannot be saved, so each postback looks like the selected index has been changed. In above code, I see you set the EnableViewState of TabContainer as false.
So the three dropdownlist's selected index cannot be saved and it will appear the scenes you descibed. Please set the property EnableViewState of TabContainer as true.
Then try it again. Thanks.
Best Regards!
We are trying to better understand customer views on social support experience. Click HERE to participate the survey. Thanks!
All-Star
30411 Points
3628 Posts
Re: Bugs in TabContainer and Accordion
Oct 18, 2013 01:33 AM|Fuxiang Zhang - MSFT|LINK
Hi mc9000,
I'm glad to you post issue to asp.net forum.
Based on your description and code provided, I see that if the dropdownlist selected item is not the initial item, once page post back, event
SelectedIndexChanged will be fired. As we know that if ViewState is disabled on the page or on the DropDownList control, the selected index
cannot be saved, so each postback looks like the selected index has been changed. In above code, I see you set the EnableViewState of TabContainer as false.
So the three dropdownlist's selected index cannot be saved and it will appear the scenes you descibed. Please set the property EnableViewState of TabContainer as true.
Then try it again. Thanks.
Best Regards!