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.

RowLeave Event in GDBG

Thread ID:





51208 Oct 31,2006 09:42 AM Nov 1,2006 12:13 AM Windows Forms 1
Tags: GridControl
Simon Kakon
Asked On October 31, 2006 09:42 AM

I want to be notify when the current position in a gdbg (bounded with a datatable) is changing and have the origin row and the target row index.

The rowleave event works fine but it doesn't give the target row index !

Thanks for your help.

Administrator [Syncfusion]
Replied On November 1, 2006 12:13 AM

Hi Simon,

Using RowEnter Event:

You can handle the RowEnter event to find the target row in a grid. Here is a code snippet

private void gridDataBoundGrid1_RowEnter(object sender, Syncfusion.Windows.Forms.Grid.GridRowEventArgs e)
Console.WriteLine("gridDataBoundGrid1_RowEnter Target Row : " + e.RowIndex);

Using CurrentCellMoving Event:

You can use the CurrentCellMoving event to get the origin row and target row in a grid. Please find the code snippet below.

private void gridCurrentCellMoving(object sender, GridCurrentCellMovingEventArgs e)
GridCurrentCell cc = this.gridDataBoundGrid1.CurrentCell;
if(cc.MoveToRowIndex != cc.MoveFromRowIndex)
Console.WriteLine("Origin Row: " + cc.MoveFromRowIndex);
Console.WriteLine("Target Row: " + cc.MoveToRowIndex);

Here is a sample.

Best Regards,


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.

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.