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

RadGridView SelectionChanged/SelectedCellsChanged does not trigger

1 Answer 293 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Sri
Top achievements
Rank 1
Sri asked on 19 Jun 2014, 01:09 PM
I have a wpf radgrid view with two columns. And the configuration
of it is like below.

SelectionMode = “Extended”

SelectionUnit=”Cell”

List of columns = 2

Out of two columns, one of them is a combobox column and the
template is same for celltemplate and celledittemplate. (As I want consistent
UI irrespective of cell in edit or not)

With the above setup, when user clicks on a radcombobox,
none of the selection events are raised which is causing me to identify the
active column/row.

Can somebody provide me any resolution? I can provide
example if required.

1 Answer, 1 is accepted

Sort by
0
Dimitrina
Telerik team
answered on 20 Jun 2014, 12:40 PM
Hello,

As I understand you are selecting on RadComboBox, not on GridViewCell. If so, then the selection events of RadGridView will not be raised. The SelectionChanged event of RadComboBox will be raised instead.

If you want to detect a click on the cell/row, then you can subscribe for the MouseLeftButtonDown event.
For example:
this.AddHandler(FrameworkElement.MouseLeftButtonDownEvent, new MouseButtonEventHandler(OnMouseLeftButtonDown), true);
private void OnMouseLeftButtonDown(object sender, MouseButtonEventArgs e)
{
}

Furthermore, if you define an editor as CellTemplate, then you do not need to define such as CellEditTemplate, simply because you will be doing all the editing through the CellTemplate. 

Regards,
Didie
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
Tags
General Discussions
Asked by
Sri
Top achievements
Rank 1
Answers by
Dimitrina
Telerik team
Share this question
or