hello,
I have webdropdown , when I add items at desgin time it cannot display its container list which will contain the items I add, I sepose;however when I bound a datasource to it ,the webdropdown displays the container list and text field in the datasource.
here is the code when use items:
<asp:UpdatePanel ID="UpdatePanel2" runat="server" UpdateMode="Conditional"> <ContentTemplate><asp:FormView ID="FormView1" runat="server"><InsertItemTemplate><table><tr><td style="text-align: left"> <ig:WebDropDown ID="WebDropDown1" runat="server" DropDownAnimationType="Linear" DropDownContainerHeight="0px" DropDownContainerMaxHeight="0px" DropDownContainerWidth="0px" EnableDropDownAsChild="False" MultipleSelectionType="Checkbox" PageSize="0" TextField="id" Width="200px"><ClientEvents Initialize="initDropDown" /><DropDownItemBinding TextField="id" /><Items><ig:DropDownItem Disabled="False" IsCustom="False" Selected="False" Text="aaa" Value="aaa"></ig:DropDownItem><ig:DropDownItem Disabled="False" IsCustom="False" Selected="False" Text="bbb" Value="bbb"></ig:DropDownItem><ig:DropDownItem Disabled="False" IsCustom="False" Selected="False" Text="ccc" Value="ccc"></ig:DropDownItem></Items></ig:WebDropDown></td></tr></table></InsertItemTemplate></FormView> </ContentTemplate></UpdatePanel>
function initDropDown(sender, args) {
sender.behavior.set_zIndex(999999999);
}
thanks Inadvance
Hello sunqy1212,
If you need any further assistance with the matter, please do not hesitate to ask.
Hi sunqy1212,
It seems that this behavior is caused by the FormView control. It is displaying only data-bound values, so the templated WebDropDown only works when a datasource is set.
Please let me know if you have any further questions.