Dynamically creating combobox columns in codebehind/event

2 posts, 0 answers
  1. Kevin
    Kevin avatar
    4 posts
    Member since:
    Sep 2012

    Posted 31 Oct 2013 Link to this post

    We are using dynamically creating combo column. please give us some suggestions:
    Purposes:
    1. dynamic columns
    2. dynamic columns with combox box.
    3. after selection, combobox will effect other columns (calculation)

    It is impossible to declare GridViewComboBoxColumn in xaml because of columns is dynamic.
    There will have serveral dynamic columns which are combobox and each row has different itemsource.
    We have tried following possible workaround but it fails including 
    1. blank cell when loading 
    2. selection is not reflect back to cell.

    Event 
    private void RadTreeListView1_DataLoaded(object sender, System.EventArgs e)
          {
              GridViewComboBoxColumn column = new GridViewComboBoxColumn();
     
              column.SelectedValueMemberPath = "TestID";
              column.UniqueName = "Hello";
              column.ItemsSourceBinding = new Binding("MySchool");
              column.DataMemberBinding = new Binding("ID");
              column.DisplayMemberPath = "Name";
              this.RadTreeListView1.IsSynchronizedWithCurrentItem = true;
     
              this.RadTreeListView1.Columns.Add(column);
              // TODO: Add event handler implementation here.
          }

    Issue see 1.jpg.
    Please advise us for how to resolve this issue.

    After a lot of reference, there are some workaround, but still failed:
    1. create custom cell control and override createCellEditTemplate Method.
    2. using xml.loader for cellEditTemplate xml.
    3. using dynamic runtime object when dropdown list is open.
    4. using datacontext and dataproxy to dropdown list.
    5. assign itemssouce to combobox.
    6. set itemssourcebinding to combobox.

    After all. The precondition is those columns are dynamic. so some solutions may not working for our project.

    Please give us some solutions. 

    Thanks 
  2. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 01 Nov 2013 Link to this post

    Hi Kevin,

    Will it be possible to clarify whether you are still dealing with those issues since in the project you sent in one of your other tickets those requirements were met ?  Do you need any assistance with the implementation ?

    Regards,
    Maya
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  3. DevCraft banner
Back to Top