Binding Item Template to a Dataset

2 posts, 0 answers
  1. Rodney
    Rodney avatar
    54 posts
    Member since:
    Mar 2015

    Posted 26 Apr Link to this post

    Hi,

    I'm trying to create a multi-column dropdown list based on this example: Telerik APS.Net ComboBox Demo. My problem is I'm getting my data back as a DataSet, it's not a DataSource, and I'm unclear as to how to bind the dataset to the control. I tried using the evals etc as described in the example, but I get an error DataSource expected.

    Any help would be greatly appreciated.

    Rodney

  2. Marin Bratanov
    Admin
    Marin Bratanov avatar
    3916 posts

    Posted 28 Apr Link to this post

    Hello Rodney,

    I have answered your support ticket with this question and I am adding my response here for anyone else with a similar question


    Where the data comes from is not really relevant, what is important is that it contains the needed fields (columns).

    Can you confirm that you have also copied the CSS from the demo? Also, the first combo uses load on demand, yet its template and the databinding expressions are in the markup. The Text and Value are set so the combo can continue working like a combo regardless of the elaborate display change. The Value, for example, is needed for the POST and so you can identify selected item, the Text is also there so the combo API can work.

    I am attaching here a modified version of the demo that contains the styles, the script and data binds to a data set in the server code. I hope this helps you move onward.

     

     

    Regards,

     

    Marin Bratanov
    Telerik by Progress
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top