Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Grid Column width disabled

Status
Not open for further replies.

billthom

Programmer
Feb 18, 2009
1
0
0
US
I would like to set the column width (of a column in a data window grid) using the properties tab, but the width property is disabled; forcing me to use the mouse to drag to an approximate size.

Why is the width disabled, and can this be fixed or worked around?
 
The columns defined by the grid lines in a Grid DataWindow are a function of the presentation style. Other objects besides the data column objects may be associated with each grid column, such as Header text objects or computed field objects in the Summary or Footer bands, so the X and Width properties of all these objects depends on the display properties of all the other objects in same or previous grid columns. The X and Width properties are disabled on these objects in the DataWindow Painter because these values are recalculated each time the Datawindow is opened in the painter.

If you wanted to set a column to a specific width you could edit the source code of the Datawindow and set the width of the data column object in the Detail band to the desired value. This should set the grid column to that width 99% of the time but it will be recalculated to the nearest PowerBuilder Unit (or whatever Unit you are using for your DataWindows) the next time the Datawindow is opened in the painter.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top