Alternate event to SourceListListChanged event in gridGroupingControl

Hi Clay, I have a requirenment when the user moves from one row to other, I want to update row values to database. Currently I am using SourceListListChanged event. We are looking for performance improvement and observed this is costly as it raises in many a times. Kindly suggest some other event to do the same functionality. Thanks, Prathima

3 Replies

AD Administrator Syncfusion Team August 11, 2005 08:34 AM UTC

You can catch when your user leaves a record using the CurrentRecordContextChange and checking the e.Action to pick out the leave. private void gridGroupingControl1_CurrentRecordContextChange(object sender, CurrentRecordContextChangeEventArgs e) { if(e.Action == CurrentRecordAction.LeaveRecordComplete) { Console.WriteLine(e.Record); } }


PV Prathima Venkobachar August 11, 2005 10:15 AM UTC

On this event can I make a check whether the row has been modified or not..? Thanks, Prathima


AD Administrator Syncfusion Team August 11, 2005 10:52 AM UTC

You can try code similar to this.
private bool recordEdited = false;		
private void gridGroupingControl1_CurrentRecordContextChange(object sender, CurrentRecordContextChangeEventArgs e)
{
	if(e.Action == CurrentRecordAction.EndEditComplete)
	{
		recordEdited = true;
	}
	else if(e.Action == CurrentRecordAction.EnterRecordComplete)
	{
		recordEdited = false;	
	}
	else if(e.Action == CurrentRecordAction.LeaveRecordComplete)
	{
		if(recordEdited)
			Console.WriteLine(e.Record);
	}
}

Loader.
Up arrow icon