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.

Moving Columns and FilterBar

Thread ID:





37487 Nov 23,2005 02:14 AM Nov 23,2005 08:35 AM Windows Forms 4
Tags: GridControl
Administrator [Syncfusion]
Asked On November 23, 2005 02:14 AM

When i attach a custom FilterBar on my grid which has column dragging option enabled the filter bar is not working (does not accept any input), but it does when i remove the GridControllerOptions.DragColumnHeader setting. Am i missing something here? Is this behaviour correct ?

Administrator [Syncfusion]
Replied On November 23, 2005 04:21 AM

I tried to see this behavior in the sample we ship, but moving columns seems to work OK there, not affecting the filtering. \Essential Studio\\Windows\Grid.Windows\Samples\DataBound\FilterBarGrid Can you see the problem in this sample somehow? In your customization, are you woring with hard coded column indexes some how? If you can upload a sample project showing the problem or tell us how to see it in the above sample, maybe we can suggest a solution.

Administrator [Syncfusion]
Replied On November 23, 2005 04:37 AM

I can see the problem. I just thought you were using AllowDragCols. But setting the other option does break something. Will look into it.

Administrator [Syncfusion]
Replied On November 23, 2005 07:32 AM

The problem is that the filter row is really a second header row. And this DragColumnHeader mouse controller handles all clicks into headers. This is why the dropdown is not happening. Try this. Subscribe to the QueryAllowDragColumnHeader event, and there have code like:
private void gridDataBoundGrid1_QueryAllowDragColumnHeader(object sender, GridQueryDragColumnHeaderEventArgs e)
	int row, col;
	Point pt = this.gridDataBoundGrid1.PointToClient(Control.MousePosition);
	if(this.gridDataBoundGrid1.PointToRowCol(pt, out row, out col) && row == 1)
		e.AllowDrag = false;

Administrator [Syncfusion]
Replied On November 23, 2005 08:35 AM

you''re right it works fine thanks Clark


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.