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.

Drag Drop of columns

Thread ID:

Created:

Updated:

Platform:

Replies:

81243 May 18,2009 09:25 AM May 19,2009 11:30 AM Windows Forms 1
loading
Tags: GridControl
Administrator [Syncfusion]
Asked On May 18, 2009 09:25 AM

Hi,

I'm currently working with Sycfusion Ver 6.1.0.34. My objective is when we drop a column we see whether its dependent on any other column if so we need to move all the dependent column along with it to the target position. Assume that the dependent columns are always sequential. I tried handling the case in Grid.ColsMoving event and capture the column # to see whether its dependent. I tried selecting the dependent column in the ColsMoving event but dont know how to stop this move and start a new move of all the dependent columns Please help me out of this issue

Thanking you in advance

Regards
damo...

Rajadurai C [Syncfusion]
Replied On May 19, 2009 11:30 AM

Hi Damodhar,

Thanks for your interest in Syncfusion products.

To prevent a column from being dropped to certain column while moving, please try to handle the following code in ColsMoving event.

private void gridControl1_ColsMoving(object sender, Syncfusion.Windows.Forms.Grid.GridRangeMovingEventArgs e)
{
if(e.Target == 3)
{
e.Cancel = true;
this.gridControl1.Cols.MoveRange(e.From,1,e.From);
}
}

This prevents the column moved from being dropped, if the target column is 3rd in grid.

Regards,
Rajadurai

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.

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.

;