Hello Hadhan,
Now I got little problem for GroupingGridControl with Multiple Primary Keys table.
when I add a new row, enter first Primary key cell, leave the cell, this line ''this.gdBase.Table.EndEdit'' displays validation error Messagebox saying the second Primary Key cell can''t be null, when you click Messagebox''s OK, the content entered in the first Primary Key cell disappeared, the cursor moves to the second Primary Key cell. This makes you can never finish to enter a new row.
Please see two attached meesage files.
How can I get around? Thanks.
Lan Mo
my code:
private void gdBase_TableControlCurrentCellAcceptedChanges(object sender, Syncfusion.Windows.Forms.Grid.Grouping.GridTableControlCancelEventArgs e)
{
// accept cell change
this.gdBase.Table.EndEdit();
DimButtons();
}
>Hi Madhan,
>Thank you very much. It works for me.
>Regards,
>
>Lan
>
>
>
>
>>Hi Lan,
>>
>>The problem you are facing is that, by default the new value is stirred in a local row cache and is being flushed to the datasource only when the row changes. If you want to do this on a cell by cell basis, then say in CurrentCellAcceptedChanges, first call EndEdit before you call Update.
>> Here is the code snippet
>>
>> private void gridGroupingControl1_TableControlCurrentCellAcceptedChanges(object sender, Syncfusion.Windows.Forms.Grid.Grouping.GridTableControlCancelEventArgs e)
>> {
>> this.gridGroupingControl1.Table.EndEdit();
>> this.sqlDataAdapter1.Update(this.dataSet11);
>> }
>>
>>Best regards,
>>Madhan
>>
GridValidateMsg.zip