This question is locked. New answers and comments are not allowed.
I had 2 questions with regard to DataGrid
1) Is it possible to click on different columns on a grid to get different details?
As an example in the myTweets demo, if I click on the name, the details of the author should be displayed.
If I click on the Tweet, I would like a RADEditor to pop up.
2) Is there a way to disable showing "Drag a column Header..."
Thanks
Sally
1) Is it possible to click on different columns on a grid to get different details?
As an example in the myTweets demo, if I click on the name, the details of the author should be displayed.
If I click on the Tweet, I would like a RADEditor to pop up.
2) Is there a way to disable showing "Drag a column Header..."
Thanks
Sally
4 Answers, 1 is accepted
0
Hello Sally,
Both are possible ,
I have demosntrated this in the attached sample project.
Kind regards,
Pavel Pavlov
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Both are possible ,
I have demosntrated this in the attached sample project.
Kind regards,
Pavel Pavlov
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Silly
Top achievements
Rank 1
answered on 17 Dec 2009, 07:22 PM
Hello Pavel,
Thank you so much for putting together a sample for me. I really am grateful for that. But the behavior does not seem to be consistent. Initially when I tried, the 1st and the last row, always displayed the Name, while the other rows worked properly. Now it seems that the rows alternate between displaying the ID and Name, regardless of what is being clicked. Is this a known issue?
Specifically, can you tell me as how I control them. For instanct, is there an OnClick, or OnDoubleClick method that I can associate with the cell/row/header etc.
Also, what method you used to disable showing "Drag a column Header..."
Thanks
Sally
Thank you so much for putting together a sample for me. I really am grateful for that. But the behavior does not seem to be consistent. Initially when I tried, the 1st and the last row, always displayed the Name, while the other rows worked properly. Now it seems that the rows alternate between displaying the ID and Name, regardless of what is being clicked. Is this a known issue?
Specifically, can you tell me as how I control them. For instanct, is there an OnClick, or OnDoubleClick method that I can associate with the cell/row/header etc.
Also, what method you used to disable showing "Drag a column Header..."
Thanks
Sally
0
Silly
Top achievements
Rank 1
answered on 18 Dec 2009, 06:15 AM
Thanks so much Pavel for the demo that you put together. But I am having problems with the demo. The behavior is not consistent. Somethimes, the ID is displayed, sometimes Name, but not at any time on a row only ID or Name is displayed. ie if I click on ID also, ID is displayed, and if I click on Name also ID is displayed. On other row, if I click on ID also Name is displayed, and if I click on Name also Name is displayed. So it is not very consistent.
What I don't understand is how are these events bound to the cells. For example I don't see any binding of OnClick event to these cells.
Also, when you disabled showing "Drag a column Header..." I don't see anywhere in the code where you explicitly did it.
I am sorry, but I am relatively new to WCF and Silverlight. So I apologize if my questions are trivlail.
What I don't understand is how are these events bound to the cells. For example I don't see any binding of OnClick event to these cells.
Also, when you disabled showing "Drag a column Header..." I don't see anywhere in the code where you explicitly did it.
I am sorry, but I am relatively new to WCF and Silverlight. So I apologize if my questions are trivlail.
0
Hi Sally,
I have changed the example slightly.
The event used now is RadGridView.RowDetailsVisibilityChanged
It gets fired always when row details are shown or hidden.
Here is how we get which cell was clicked by the user :
About your second quiestion - we hide the "Drag ....." text with the following piece of XAML :
ShowGroupPanel = "false"
you can also do this in code behind :
this.RadGridView1.ShowGroupPanel = false;
Regards,
Pavel Pavlov
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
I have changed the example slightly.
The event used now is RadGridView.RowDetailsVisibilityChanged
It gets fired always when row details are shown or hidden.
Here is how we get which cell was clicked by the user :
private void RadGridView1_RowDetailsVisibilityChanged(object sender, Telerik.Windows.Controls.GridView.GridViewRowDetailsEventArgs e) { if (e.Visibility == Visibility.Visible) { var cellSelected = ((RadGridView)sender).CurrentCell; e.DetailsElement.DataContext = cellSelected.Value; } }About your second quiestion - we hide the "Drag ....." text with the following piece of XAML :
ShowGroupPanel = "false"
you can also do this in code behind :
this.RadGridView1.ShowGroupPanel = false;
Regards,
Pavel Pavlov
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.