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

Checkbox not being saved

2 Answers 66 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Derek
Top achievements
Rank 1
Derek asked on 11 Nov 2008, 12:58 PM
Hi,
I have a RadGridView that is populated by dynamic SQL.  When I click a checkbox field and click 'Save' the checkbox reverts back to off.  Any ideas ?

Thanks,
Derek.

2 Answers, 1 is accepted

Sort by
0
Accepted
Nikolay
Telerik team
answered on 14 Nov 2008, 11:28 AM
Hello Derek,

You are correct. When you check/uncheck a RadCheckBoxEditor and right after that click the Save button, (without selecting other row first) the value is not persisted. In order to workaround this behavior, please call the EndEdit() method of RadGridView:
private void radButton1_Click(object sender, EventArgs e)  
{  
    this.radGridView1.EndEdit();  
    this.productsTableAdapter.Update(this.nwindDataSet.Products);  

This issue will be addressed in one of our next releases. If you have additional questions, feel free to contact me.

All the best,
Nikolay
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Derek
Top achievements
Rank 1
answered on 14 Nov 2008, 03:43 PM
Thanks !
Tags
GridView
Asked by
Derek
Top achievements
Rank 1
Answers by
Nikolay
Telerik team
Derek
Top achievements
Rank 1
Share this question
or