This is a migrated thread and some comments may be shown as answers.

Combobox arrow not showing a in a combobox cell

1 Answer 169 Views
This is a migrated thread and some comments may be shown as answers.
Top achievements
Rank 1
Erez asked on 06 Aug 2009, 12:21 PM


I know how to create a combobox column and fill it with value, however

each combobox cell in the column does not show the drop down arrow, unless

the user clicks on the cell.

I tries using a combobox template on the column and visually it works, however when I do so

the combobox's possible values are not displayed in its drop down.

Hope you can assist.



1 Answer, 1 is accepted

Sort by
Rossen Hristov
Telerik team
answered on 07 Aug 2009, 10:11 AM
Hello Erez,

Each cell has two modes -- normal and edit. While in normal mode you do not see the editor (combo in this case). Only when the cell enters edit mode (the user clicks on it) the editor is loaded and could be seen. That is why you do not see the combo arrow -- in fact when the cell is in normal mode you are actually seeing a TextBlock and not a combo.

If you would like to see a combo all the time you should define a cell template for the column. I have prepared a small sample project that does this. The basic idea is that there will be a pair of combos -- one is the editor coming automatically from the GridViewComboBoxColumn and the other one is the one I have defined inside the CellTemplate. I have made the second one green just for distinction. The good news is that you can edit data from both combos. To be able to enter into edit mode though you will have to press F2 since we have redefined the cell template and the double click will no longer work. When using the "green" combo you will be actually editing data without entering into edit mode :)

                    DataMemberBinding="{Binding PersonTypeID, Mode=TwoWay}" 
                    ItemsSource="{StaticResource comboItemsSource}" 
                                    ItemsSource="{StaticResource comboItemsSource}" 
                                    SelectedValue="{Binding PersonTypeID}"

Please, examine the attached project and let me know if you have any other questions.

the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Asked by
Top achievements
Rank 1
Answers by
Rossen Hristov
Telerik team
Share this question