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.

about drag and drop event while reordering columns

Thread ID:

Created:

Updated:

Platform:

Replies:

59383 Apr 12,2007 01:20 AM Apr 12,2007 06:44 AM Windows Forms 3
loading
Tags: Grouping
ejaz
Asked On April 12, 2007 01:20 AM

Hi,
I am using GridGrouping and need to store sequence of the columns in a collection.I am able to change the position of the column or can reorder but not getting any event for that to get the column which is being moved to another posiion.I need to change the order of the columns and store them in some collection so that next time if I bind grid to the datasource it should display columns in new order which is changed last time.

Regards,
Ejaz

Jeba S [Syncfusion]
Replied On April 12, 2007 06:19 AM

Hi Ejaz,

Please try handling TableControlQueryAllowDragColumn event hanlder and see if it helps.

private void gridGroupingControl1_TableControlQueryAllowDragColumn(object sender, GridQueryAllowDragColumnEventArgs e)
{
Console.WriteLine("gridGroupingControl1_TableControlQueryAllowDragColumn");
}

Kindly let us know if this helps.

Best Regards,
Jeba.

ejaz
Replied On April 12, 2007 06:27 AM

Hi Jeba,

Thanks,I tried that,but it fires before start of draging column and I need one event which fires after drop of the column

Best Regards,
Ejaz



>Hi Ejaz,

Please try handling TableControlQueryAllowDragColumn event hanlder and see if it helps.

private void gridGroupingControl1_TableControlQueryAllowDragColumn(object sender, GridQueryAllowDragColumnEventArgs e)
{
Console.WriteLine("gridGroupingControl1_TableControlQueryAllowDragColumn");
}

Kindly let us know if this helps.

Best Regards,
Jeba.

Jeba S [Syncfusion]
Replied On April 12, 2007 06:44 AM

Hi Ejaz,

Please try this code snippet to get the column which is moved to another position.

private void gridGroupingControl1_TableControlQueryAllowDragColumn(object sender, GridQueryAllowDragColumnEventArgs e)
{

if (e.Reason == GridQueryAllowDragColumnReason.MouseUp)
{
Console.WriteLine("gridGroupingControl1_TableControlQueryAllowDragColumn");
Console.WriteLine("Moved Column="+ e.Column.ToString());
}
}


Best Regards,
Jeba.

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.

;