Wael Joulani Wael Joulani -5 years ago 186
Javascript Question

How to get top(n) from kendo AutoComplete client side when filtering

I have the below autocomplete set to static


dataTextField: AutoCompletedataTextField,
filter: "startswith",
ignoreCase: true,
pageSize: 10,
dataSource: tempArray,

I need to get only top 10 items to be displayed in the control.
how can I achieve this?

Answer Source

I solved it by setting the page size inside the dataSourceBlock

 dataSource: {
    data: tempArray,
    pageSize: 10
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download