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

Edit checkbox column

5 Answers 90 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Richard Koslik
Top achievements
Rank 1
Richard Koslik asked on 01 Feb 2011, 02:36 PM
Hello!

I have now implemented a RadGridView with two columns, one checkbox and one textfield. The checkbox is editable and the textfield not. My question now: Is it normal that I have to click three times into the checkbox column for editing the checkbox. I also tried it at your Silverlight tutorial and it works the same! Why? The grid in the Ajax Tutorials works, why not in Silverlight?

- 1st click: column is selected
- 2nd click: column is in edit mode
- 3rd click: value of column is changed

Best regards, Richard Koslik

5 Answers, 1 is accepted

Sort by
0
Vlad
Telerik team
answered on 01 Feb 2011, 02:39 PM
Hi,

Have you tried to set EditTriggers to "CellClick"?

Greetings,
Vlad
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0
Accepted
Veselin Vasilev
Telerik team
answered on 01 Feb 2011, 02:44 PM
Hi Richard Koslik,

Setting the EditTriggers to CellClick will reduce the number of clicks to two - one for entering edit mode and one to change the value of the checkbox.
If you need to change the value with one click as a whole, you need to set AutoSelectOnEdit="True" as well.
So, here is the final definition:

<telerik:GridViewCheckBoxColumn DataMemberBinding="{Binding IsActive}"
                 AutoSelectOnEdit="True"
                 EditTriggers="CellClick" />



All the best,
Veselin Vasilev
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0
Richard Koslik
Top achievements
Rank 1
answered on 01 Feb 2011, 03:39 PM
Hello!

Thanks for your fast answers, it works now!

Regards, Richard Koslik
0
or hor
Top achievements
Rank 1
answered on 07 Mar 2011, 08:27 AM

yes, and what to do in the case the columns are generated automatically?

thank you in advance

0
Maya
Telerik team
answered on 07 Mar 2011, 08:35 AM
Hello Richard Koslik,

You may try to handle the AutoGeneratingColumn event of the grid and set the EditTriggers property for the column you want.
 

Best wishes,
Maya
the Telerik team
Registration for Q1 2011 What’s New Webinar Week is now open. Mark your calendar for the week starting March 21st and book your seat for a walk through all the exciting stuff we ship with the new release!
Tags
GridView
Asked by
Richard Koslik
Top achievements
Rank 1
Answers by
Vlad
Telerik team
Veselin Vasilev
Telerik team
Richard Koslik
Top achievements
Rank 1
or hor
Top achievements
Rank 1
Maya
Telerik team
Share this question
or