Adding diff column types to same column for diff rows

6 posts, 0 answers
  1. Richard Harrigan
    Richard Harrigan avatar
    235 posts
    Member since:
    Nov 2009

    Posted 14 May 2013 Link to this post

    Hi,

    I have tried to get the answer to this critical question (for me) but I probably have not stated the question properly.....How do I get a different drop down list in different rows of the same column?  The Below grid example is what i need to do.  The example below is only for descriptive purposes to visually depict what I have not been able to verbally explain.  A simple working example would be greatly appreciated.

    Thanks
    Rich

    Row No Month Column Sales Column
    1 Drop Down Combo box 100.00
    January
    February
    March

    2 Drop Down Combo box 120.00
    April
    May
    June

    3 Drop Down Combo Box  80.00
    July
    August
    September

    etc.
  2. Dimitrina
    Admin
    Dimitrina avatar
    3769 posts

    Posted 15 May 2013 Link to this post

    Hi,

    You should define the Items for the GridViewComboBoxColumn as a collection for the business object (bound to the parent row) and then set the ItemsSourceBinding specifying it.
     

    Kind regards,
    Didie
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. Richard Harrigan
    Richard Harrigan avatar
    235 posts
    Member since:
    Nov 2009

    Posted 15 May 2013 Link to this post

    Hi Didie,

    Would you please provide an example or a code snippet that shows how to do this.

    Thanks
    Rich 
  4. Dimitrina
    Admin
    Dimitrina avatar
    3769 posts

    Posted 17 May 2013 Link to this post

    Hello Rich,

    For every data item (with row numbers 1, 2, 3, etc.), you should define and set a Months collection. Then specify it as ItemsSourceBinding for the column. You can check this help article for additional details.

    Regards,
    Didie
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  5. Richard Harrigan
    Richard Harrigan avatar
    235 posts
    Member since:
    Nov 2009

    Posted 17 May 2013 Link to this post

    Hi Didie,

    On the 2nd example (Drivers), may I have the full source code so I can run it?

    The document refers to 3 Current Driver collections.  How does each row bind to the correct driver collection?  Based on the ItemSource presented the DriverID column must be binding to the correct Drivers Collection based on the value of the TeamID column.  I don't understand how that actually happens.  Is this happening in some event?  What does the rest of the xaml for the RadGridView look like.

    Thanks
    Rich





  6. Dimitrina
    Admin
    Dimitrina avatar
    3769 posts

    Posted 18 May 2013 Link to this post

    Hello,

    You can find attached a demo project showing how you can configure the ItemsSource for the GridViewComboBoxColumn per item level.

    Regards,
    Didie
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Back to Top