What Are The Available DGH Properties For Custom Headers?

Here is the list of possible properties for Custom Headers:

  • header control alignment: Change the control alignment. Can be left, right or center
  • header control top margin: Numeric - Add a margin between the header control and the top border of the data grid. Can be 0, a positive or negative value.
  • checkbox label visible: Boolean - true to show the checkbox label, false to hide it
  • checkbox label: Text - Change the label of the checkbox.
  • checkbox hilite: Boolean - true to hilite the checkbox. The content of the column will change accordingly., This can be used to check/uncheck a whole column.
  • image id: Integer - the image id
  • widget svg path: SVG path - to change the widget control appearance
  • ascending sort icon: SVG path - to change the ascending sort icon appearance
  • descending sort icon: SVG path - to change the descending sort icon appearance

Accessing the Custom Header Properties

To read (get) the properties linked to a custom column header, you can use the following code:

put "myCol" into tColumn
put the dgh_CustomHeaderColumn of grp "myDataGrid" into tData

put tData[tColumn]["header control alignment"] into tTheHeaderControlAlign
put tData[tColumn]["header control top margin"] into tTheHeaderControlTopMargin
put tData[tColumn]["checkbox label visible"] into tCheckBoxLabelVisible
put tData[tColumn]["checkbox label"] into tCheckBoxLabel
put tData[tColumn]["checkbox hilite"] into tHiliteFlag
put tData[tColumn]["image id"] into tImgRef
put tData[tColumn]["widget svg path"] into tSVGPath
put tData[tColumn]["ascending sort icon"] into tASVGPath
put tData[tColumn]["descending sort icon"] into tDSVGPath

And to set a value, you can use this code:

put "myCol" into tColumn
put the dgh_CustomHeaderColumn of grp "myDataGrid" into tData
put true into tData[tColumn]["checkbox hilite"]
set the dgh_CustomHeaderColumn of grp "myDataGrid" to tData


Add your comment

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.