After initializing my dropdown and setting the selectedItemIndex to -1, I would have thought when selecting the first item in the dropdown (with index of 0), it would trigger the selectionChanged event. This doesn't appear to be happening. I have confirmed the dropdown activeitemindex and selecteditemindex are set to -1, but the event doesn't get fired until you have selected any other item except the first item in the list.
Idea's/thoughts/solutions?
Paul
Hello,
Thank you for posting in our community.
Please make sure you have enabled both AutoPostBackFlags for SelectionChanged as well as specifying the event handler. For example:
OnSelectionChanged="WebDropDown1_SelectionChanged"><AutoPostBackFlags SelectionChanged="On" />
I am attaching a runnable code sample to my reply, in order for you to see a working implementation and to be able to play a bit with it. Please let me know in case you have any questions or concerns regarding this matter.
yep, I have that all in place. The problem is with selecting the first item and it is defined through code-behind.
<ig:WebDropDown ID="webdropDown1" runat="server" Width="350px" DisplayMode="DropDownList" EnableCustomValues="False" EnableCustomValueSelection="False" AutoPostBack="True" OnSelectionChanged="webDropDown1_SelectionChanged" StyleSetName="LucidDream"> <AutoPostBackFlags SelectionChanged="On" /></ig:WebDropDown>