Dropdown selectedindexchanged event firing when submit button clic

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

I have a web control button that I use for submitting a form, for some
reason this causes a dropdownlist web control I have in a panel at the top of
the form to execute it's selected index changed event even though on this
postback that value hasn't been changed. I believe viewstate and validation
are causing this value to be considered changed somehow. When the page is
first loaded the only control that causes postback is this dropdown, then on
rerendering the page, it displays another panel that goes with the value
selected in the dropdown.

Any ideas?

Please help thanks.
 
Is the DropDownList's ViewState disabled? If so, then it can cause odd side-effects
if you're relying upon it's eventing behavior. IOW, if you are using the
SelectedindexChanged event, you can't disable viewstate.

-Brock
DevelopMentor
http://staff.develop.com/ballen
 
Um like a moron, I forgot to enable viewstate for the panel that the dropdown
is contained in. lol
 
Back
Top