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

RadContextMenu

2 Answers 83 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Marc Roussel
Top achievements
Rank 2
Marc Roussel asked on 12 Mar 2010, 06:07 PM
Hi,

I'm trying a code sample found in the demo here I think and it doesn't do what I tought it would do.

private void _rcmJobs_Opened(object sender, RoutedEventArgs e)  
{  
    GridViewRow row = ((Telerik.Windows.RadRoutedEventArgs)e).OriginalSource as GridViewRow;  
 
    if (row != null)  
        row.IsSelected = row.IsCurrent = true;  
}  
 

When I right click on a row which isn't the selected one, it doesn't select the row.
How do I make it so when I right click to open the ContextMenu it is also selecting the line I right clicked on ?

2 Answers, 1 is accepted

Sort by
0
Accepted
Vlad
Telerik team
answered on 15 Mar 2010, 07:37 AM
Hello ,

The same approach can be on this demo and everything is working fine.

Greetings,
Vlad
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
Marc Roussel
Top achievements
Rank 2
answered on 15 Mar 2010, 11:49 AM
Awesome.  It works like a charm.  Thank you
Tags
GridView
Asked by
Marc Roussel
Top achievements
Rank 2
Answers by
Vlad
Telerik team
Marc Roussel
Top achievements
Rank 2
Share this question
or