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.

adjusting column width with hierachical GridDataBoundGrid

Thread ID:

Created:

Updated:

Platform:

Replies:

45529 Jun 22,2006 02:22 PM Jun 22,2006 04:51 PM Windows Forms 2
loading
Tags: GridControl
Nick M
Asked On June 22, 2006 02:22 PM

Hello, I am have been unable to successfully change column widths with my 3-level hierachy grid. I am using InternalColumns. I am using DataTables and DataSets as a data source. Snippet: ------- GridHierarchyLevel level0 = gridDataBoundGrid1.Binder.RootHierarchyLevel; level0.InternalColumns[1].MappingName = "test"; gridDataBoundGrid1.Model.ColWiths["test"]= 250; ------- I would expect this to set the column width of the second column to 250. It does not. Changing the index or mapping name does not change any of the column widths. What am I doing wrong? Thanks, Nick

Administrator [Syncfusion]
Replied On June 22, 2006 02:41 PM

Hi Nick, In general grid should automatically resize columns to fit cell contents on first disply of the data. To turn off the this behavior, you need to set the AllowResizeToFit property to false. Please find the code snippet below. this.gridDataBoundGrid1.AllowResizeToFit = false; Let me know if this helps. Best Regards, Haneef

Nick M
Replied On June 22, 2006 04:51 PM

That did it...thanks!

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.

;