Could someone help:
I am trying to get EnableLoadOnDemand to work with my Webdropdown which I bind using a IEnumerable returned from a 'Linq to SQL' statement. The IEnumerable contains around 3697 items, thus the need for EnableLoadOnDemand. When I set EnableLoadOnDemand="true" and PageSize="50" I only get the first 50 records. When I scroll down to the bottom of the items the dropdown flashes like it's going to page and that's it. Below is the markup for my WebDropDown and the code to bind it.
<ig:WebDropDown ID="wddCustomer" runat="server" Width="110px" EnableClosingDropDownOnSelect="false" DropDownContainerWidth="110px" DropDownContainerHeight="200px" EnableMultipleSelection="true" MultipleSelectionType="Keyboard" EnableLoadOnDemand="true" PageSize="50"> </ig:WebDropDown>
' Load Customers wddCustomer.DataSource = From c In Context.Customers Where c.Cono = 1 Select New With {.CustID = c.CustId, .CustName = c.CustName}
wddCustomer.TextField = "CustID" wddCustomer.ValueField = "CustID" wddCustomer.DataBind() wddCustomer.Items.Insert(0, (New DropDownItem("All", "0")))
Hello duckkiller53,
I recommend you using lazy loading in this case:
http://help.infragistics.com/NetAdvantage/ASPNET/2010.3?page=WebDropDown_Lazy_Loading.html
http://community.infragistics.com/aspnet/media/p/87810.aspx
As you have mentioned ASP dropdown is faster because it does not allow filtering.
WebDropDown provides several DisplayModes, the default one is DropDown:
http://help.infragistics.com/NetAdvantage/ASPNET/2010.3?page=WebDropDown_Multi_mode_Display.html
Regarding IEnumerable datasource below is the online sample binding the WebDropDown to List<>
http://samples.infragistics.com/2010.3/WebFeatureBrowser/contents.aspx?showCode=true&t=WebDropDown/ProgramaticDataBinding/WebDropDown_IEnumerable.aspx~srcview.aspx?path=~srcview.aspx?path=WebDropDown/ProgramaticDataBinding/WebDropDown_IEnumerable.src
Please let us know if you need further assistance regarding this.
Anyone that's interested, I have found that binding the WebDropDown to an IEnumerable returned by a Linq To SQL query does not work. I changed to datasource to a SqlDatacontrol and everything worked. The only thing I found was that the WebDropDown is very sluggish and slow with large return sets ie: 4000 rows. The standard ASP.Net dropdown control flies compared to the WebDropDown.