I have a huge set of data which i need to bind to on demand (on keystroke). Im currently using the AutoCompleteBox in SharePoint which won't allow me to call a webservice in the style that you suggest due to the security within SharePoint:
Since you don't allow a client side method of databinding, i was wanting to know if this is the only way of doing on-demand code behind (server side) bind. I did see that there is a ontextchanged method, is there an opportunity to rebind the datasource there?
If not, is there anyway to modify the POST request that your control sends before it is sent? there is the client side onrequesting method but that doesnt seem to allow me to modify the post data at all.
5 Answers, 1 is accepted
In fact RadAutoCompleteBox uses server-side Load On Demand internally, it is a built-in feature.
So you do not need to implement anything in order to use server-side Load On Demand - simply databind the control.
Here you can find more details about RadAutoCompleteBox databinding.
the Telerik team
I don't think loadondemand handles internally by AutoCompleteBox.
Here is the sample code, I have 40 k records (employee names) in datasource. However it hangs to search for filter 'a' . Am I mistaking somewhere ? How to achieve load on demand behavior like combobox in RadAutoCompleteBox. ?
<telerik:RadAutoCompleteBox ID="RadAutoCompleteBox1" runat="server" DropDownWidth="500px"
OnDataSourceSelect="RadAutoCompleteBox1_DataSourceSelect" DataSourceID="ObjectDataSource2" AllowCustomEntry="false"
DataValueField="Value" DataTextField="Text" onclientitemsrequesting="OnClientItemsRequesting" RegisterWithScriptManager="true"
protected void RadAutoCompleteBox1_DataSourceSelect(object sender, Telerik.Web.UI.AutoCompleteBoxDataSourceSelectEventArgs e)
var dataSource = e.DataSource as ObjectDataSource;
if (dataSource != null)
dataSource.SelectParameters["SearchString"].DefaultValue = e.FilterString;
Please have a look into the sample code snippet which woks fine at my end.
I did the same, it works fine for less records. However, it hangs out for large records.
It should behave like RadComboBox load on demand, it should fetch next 10 records after click on dropdown scroll or navigating items.
Regarding the large amount of data, which is contained in the underlying datasource of the RadAutoCompleteBox the operation would be inevitably slow. However, as you are able to handle and alter the query to your DataBase, you could simply request for the TOP 100 results for example. Thus, you could significantly decrease the returned data and optimize the process.