How to suppress "inserting is not supported by data source..." msg

I am using a datasource to perform the select and delete commands. But I'd like to write my own methods for insert and update. When I do that, I get the "inserting is not supported by data source..." pop-up although my method still worked.

Is there a way to suppress that?

Thanks.

Doc2.zip

1 Reply

BP Bhuvaneswari P Syncfusion Team October 8, 2007 12:25 PM UTC

Hi ivan ,

Thank you for your interest in Syncfusion products.

To suppress this pop up please cancel the grid DataSourceControlRowAdding event. Now you can write your own methods for insert.

Code snippet:
//For insert
protected void GridGroupingControl1_DataSourceControlRowAdding(object sender, Syncfusion.Web.UI.WebControls.Grid.Grouping.GridDataSourceControlRowAddingEventArgs e)
{
e.Cancel = true;
}
//For delete
protected void GridGroupingControl1_DataSourceControlRowDeleting(object sender, Syncfusion.Web.UI.WebControls.Grid.Grouping.GridDataSourceControlRowDeleteEventArgs e)
{
e.Cancel = true;
}
//For Update
protected void GridGroupingControl1_DataSourceControlRowUpdating(object sender, Syncfusion.Web.UI.WebControls.Grid.Grouping.GridDataSourceControlRowUpdateEventArgs e)
{
e.Cancel = true;
}

Please let me know if you have any other queries.

Best Regards,
Bhuvana

Loader.
Up arrow icon