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

Button and Checkbox on Row

3 Answers 128 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Greg
Top achievements
Rank 2
Greg asked on 10 Feb 2009, 11:58 PM
I would like to have a grid with a button on each row that when pressed launches another window; the handler will have to know the contents of one of the data fields on the row (the pk) in order to display the new window. Based on the outcome of this process the user may or may not check a checkbox on that row that is not bound to data. There will be a button on the window outside of the grid that when pressed will run another process on all rows that have the checkboxes checked. I would also like to have buttons external to the grid that will check or uncheck all of the checkboxes. I have searched the examples and documentation and cannot find out how to determine the PK of the row when the button is pressed nor a way to iterate through the rows and process the ones with the checkbox checked. Some sample code would be appreciated as I'm new to WPF.

3 Answers, 1 is accepted

Sort by
0
Accepted
Stefan Dobrev
Telerik team
answered on 11 Feb 2009, 02:19 PM
Hi Greg,

I have prepared a sample solution illustrating what you are up to. Please find it in the attached archive and feel free to write back to us if you have any other questions.

Greetings,
sdobrev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Greg
Top achievements
Rank 2
answered on 11 Feb 2009, 06:27 PM
sdobrev,

Thanks that seems to meet the requirement exactly! I have  question though: In Visual Studio Team System (Version 9.0.30729.1 SP) I get an error rendering MainWindow.xaml: "Value 'Vista' cannot be assigned to property 'Theme'. Property 'Theme' of type 'Theme' cannot be specified as a string." Removing "telerik:Theming.Theme='Vista'" solves the issue.

Thanks again,
Greg
0
Stefan Dobrev
Telerik team
answered on 12 Feb 2009, 02:32 PM
Hi Greg,

I am glad to hear that the provided sample is working for you.

Regarding the VS issue - we are aware of this problem and we have already fixed it in the internal builds. The fix will be included in the next public release due in March.

Thanks again for pointing this out.

Best wishes,
Stefan Dobrev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
GridView
Asked by
Greg
Top achievements
Rank 2
Answers by
Stefan Dobrev
Telerik team
Greg
Top achievements
Rank 2
Share this question
or