How to set ItemsSrouce of GridViewComboBoxColumn for each cell

2 posts, 0 answers
  1. Nagisa
    Nagisa avatar
    14 posts
    Member since:
    Nov 2011

    Posted 27 Feb 2012 Link to this post


    I had a issue that I want to set ItemsSource of GridViewComboBoxColumn for each cell , not each column.
    Because the ItemsSource is determined by another property of entity binded to Row.

    for example,
    public class AEntity
        public string PropertyA { get; set;}
        public string ComboboxProperty { get; set;}

    ComboboxProperty  will be binded to GridViewComboBoxColumn .
    And there are two list for ItemsSrouce called ListA and ListB.

    When PropertyA is setted by "ValueA". I want to set ListA into GridViewComboBoxColumn.ItemsSource, also display value of first entity in ListA  on to Cell.
    And  when PropertyA is setted by "ValueB". I want to set ListB into GridViewComboBoxColumn.ItemsSource, and display value of first entity in ListB  on to Cell. 

    Is there any way to resolve this problem? 

    Best regards,
  2. Maya
    Maya avatar
    4062 posts

    Posted 27 Feb 2012 Link to this post

    Hello Nagisa,

    You can try using ItemsSourceBinding of GridViewComboBoxColumn instead. Furthermore, I would recommend you to run through this blog post for a reference on how to achieve similar scenario like yours. 

    All the best,
    the Telerik team
    Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
Back to Top