We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

GridDataControl Edit Mode

Thread ID:

Created:

Updated:

Platform:

Replies:

96736 Oct 1,2010 02:43 PM UTC Oct 11,2010 05:20 AM UTC Silverlight 2
loading
Tags: GridControl
Hema Gunda
Asked On October 1, 2010 02:43 PM UTC

Hi,

I just started working on Syncfusion V8.2.0.18.

My usage is to use GridDataControl to be bound to Sql Datasource, Listen row edit events and update the Database,
Create a new row and update and delete particular.

I didnt find a Event to listen on GridDataControl.

I have been hearing abt the CellChange Event, but it didnt exist in this version.

How should I use the GridDataControl for my purpose.

Appreciate your response.

Thanks.


Hema Gunda
Replied On October 4, 2010 02:05 PM UTC

We would like to work with GridDataControl in Silverlight.
(The Usage similar to ASP.NET's DataGrid Control) Should be able to Update, Insert and delete rows. We bought this product for this purpose. And, I havent seen enough functions in GridDataControl to implement this CRUD Operations.

I appreciate your quick response.

Thanks.



Balaji K [Syncfusion]
Replied On October 11, 2010 05:20 AM UTC

Hi Hema,

Thanks for your patience.

The CRUD operations are supported by GridDataControl in Silverlight. The following events help you achieve the requirement.

#Create
"RowsInserted" event is triggered when a record is added.
[Code Snippet]
this.dataGrid.Model.RowsInserted

#Update
"OnEndEdit" event is triggered when a record is updated.
[Code Snippet]
this.dataGrid.Model.CurrencyManager.OnEndEdit

#Delete
"RowsRemoved" event is triggered when a record is removed.
[Code Snippet]
this.dataGrid.Model.RowsRemoved

[Code Snippet]
this.dataGrid.ModelLoaded += ((s, e) =>
{
this.dataGrid.Model.CurrencyManager.OnEndEdit += new EventHandler(CurrencyManager_OnEndEdit);
this.dataGrid.Model.RowsInserted += new Windows.Controls.Grid.GridRangeInsertedEventHandler(Model_RowsInserted);
this.dataGrid.Model.RowsRemoved += new Windows.Controls.Grid.GridRangeRemovedEventHandler(Model_RowsRemoved);
});

Please let us know if this helps.

Regards,
Balaji


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;