Skip to main content

pgColumns

Type​

property

Summary​

Get or set the data array that the PolyGrid uses to build columns.

Syntax​

set the pgColumns of widget to <Array>
get the pgColumns of widget

Description​

Use the pgColumns property to get or set the structure of columns. The first dimension of the array uses numeric keys, each one corresponding to a column index. Internal structure of each key is as follows:

    - columnIndex[\"name\"] -- string
- columnIndex[\"label\"] -- string
- columnIndex[\"width\"] -- number
- columnIndex[\"minWidth\"] -- integer
- columnIndex[\"maxWidth\"] -- integer
- columnIndex[\"contentType\"] -- text|svg-lcname|svg-path|imagedata|imagefile|color|boolean|autoincrement|progress
- columnIndex[\"visible\"] -- boolean
- columnIndex[\"resizable\"] -- boolean
- columnIndex[\"contentAlignment\"] -- left|center|right
- columnIndex[\"headerAlignment\"] -- left|center|right
- columnIndex[\"shape\"] -- none|circle|pill|rectangle|square
- columnIndex[\"color\"] -- RGBA Color
- columnIndex[\"backColor\"] -- RGBA Color
- columnIndex[\"defaultValue\"] -- String
- columnIndex[\"textSize\"] -- Integer
- columnIndex[\"textStyle\"] -- bold|italic|plain
- columnIndex[\"fontName\"] -- String
- columnIndex[\"headerTextSize\"] -- Integer
- columnIndex[\"headerTextStyle\"] -- bold|italic|plain
- columnIndex[\"headerFontName\"] -- String
- columnIndex[\"headerOverflow\"] -- boolean

if one of the column indexes is not valid then the default column values are

    put inside that key.

Examples​

set the pgColumns of widget"PolyGrid" to tArray