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

event changing

Thread ID:

Created:

Updated:

Platform:

Replies:

72566 Mar 26,2008 07:06 PM UTC Apr 28,2008 03:07 PM UTC ASP.NET Web Forms (Classic) 5
loading
Tags: Grouping
Gilberto Barahona
Asked On March 26, 2008 07:06 PM UTC

Hi,
What is the event RecordValueChanged in control, Gripgrouping

tanks

Gilbert


Administrator [Syncfusion]
Replied On April 1, 2008 08:48 AM UTC

Hi Gilberto,

Sorry for the delay in responding.

"Recordvaluechanged event" is triggered even if record values are not changes in Edit Mode. So check for the variable, ''IsRecordValueChanged'' which is set to true if record value is changed.

In GridGroupingControl we can update the grid as well as data source more effectively by handling the CurrentRecordContextChange event than the DataSourceRowUpdating event. In CurrentRecordContextChange event you can access the current record and then you can change the value manually using SetValue method. Please refer the below code snippet which illustrates this:


[C#]
protected void GridGroupingControl1_CurrentRecordContextChange(object sender, Syncfusion.Grouping.CurrentRecordContextChangeEventArgs e)
{

//This event will be called on each action performed on a record. Here "EndEditComplete" is the final action for Editing. If this action is succeed, then data Source can be updated here.
if (e.Action == Syncfusion.Grouping.CurrentRecordAction.EndEditComplete && e.Success==true)
{
//This event is triggered even if record values are not changes in Edit Mode. So check for the variable, ''IsRecordValueChanged'' which is set to true if record value is changed.
if (IsRecordValueChanged)
{
Record r = e.Table.CurrentRecord;
r.SetValue("FirstName", "Johny");
}
}
}


Please refer the sample from the following link which illustrates the above:

http://websamples.syncfusion.com/samples/Grid.Web/6.1.0.34/F72566/main.htm

Please let me know if you have any other concerns.

Regards,
G.Yavana


Gilberto Barahona
Replied On April 4, 2008 09:42 PM UTC

Hi, G.YavanaArasy, yes is one good example, now, what do you carching, one new value, of one new record?
Tank Gilbert.

>Hi Gilberto,

Sorry for the delay in responding.

"Recordvaluechanged event" is triggered even if record values are not changes in Edit Mode. So check for the variable, 'IsRecordValueChanged' which is set to true if record value is changed.

In GridGroupingControl we can update the grid as well as data source more effectively by handling the CurrentRecordContextChange event than the DataSourceRowUpdating event. In CurrentRecordContextChange event you can access the current record and then you can change the value manually using SetValue method. Please refer the below code snippet which illustrates this:


[C#]
protected void GridGroupingControl1_CurrentRecordContextChange(object sender, Syncfusion.Grouping.CurrentRecordContextChangeEventArgs e)
{

//This event will be called on each action performed on a record. Here "EndEditComplete" is the final action for Editing. If this action is succeed, then data Source can be updated here.
if (e.Action == Syncfusion.Grouping.CurrentRecordAction.EndEditComplete && e.Success==true)
{
//This event is triggered even if record values are not changes in Edit Mode. So check for the variable, 'IsRecordValueChanged' which is set to true if record value is changed.
if (IsRecordValueChanged)
{
Record r = e.Table.CurrentRecord;
r.SetValue("FirstName", "Johny");
}
}
}


Please refer the sample from the following link which illustrates the above:

http://websamples.syncfusion.com/samples/Grid.Web/6.1.0.34/F72566/main.htm

Please let me know if you have any other concerns.

Regards,
G.Yavana




Administrator [Syncfusion]
Replied On April 7, 2008 11:01 AM UTC

Hi Gilberto,

Thank you for your update.

Could you please give more details regarding your question (what do you carching, one new value, of one new record) so that we could provide you a better solution?

Regards,
G.Yavana


Gilberto Barahona
Replied On April 7, 2008 06:22 PM UTC

Hi,
The question is: what is the event to get the new value added when a new record?


Janagan [Syncfusion]
Replied On April 28, 2008 03:07 PM UTC

Hi Gilberto,

Thanks for the update.

The currentrecordcontext change event works fine for inserting new values in the record and for updating the values in it.



C#]
protected void GridGroupingControl1_CurrentRecordContextChange(object sender, Syncfusion.Grouping.CurrentRecordContextChangeEventArgs e)
{

//This event will be called on each action performed on a record. Here "EndEditComplete" is the final action for Editing. If this action is succeed, then data Source can be updated here.
if (e.Action == Syncfusion.Grouping.CurrentRecordAction.EndEditComplete && e.Success==true)
{
//This event is triggered even if record values are not changes in Edit Mode. So check for the variable, 'IsRecordValueChanged' which is set to true if record value is changed.
if (IsRecordValueChanged)
{
Record r = e.Table.CurrentRecord;
r.SetValue("FirstName", "Johny");
}
}
}




Please refer the sample from the following link which illustrates the above:

http://websamples.syncfusion.com/samples/Grid.Web/6.1.0.34/F72566/main.htm

Please try running the sample and if still the issue exists, could you please try reproducing it in the above sample, so that we could sort out the cause and provide you a better solution>

Regards,
Janagan.








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

;