Language Reference

Control Object Properties

 

Various properties of graphical control objects in PxPlus (i.e. Button, Drop Box, Scrollbar, etc.) can be referenced and modified dynamically using a control's assigned CTL value (ctl_id) followed by the apostrophe operator and one of the associated property names.

For each graphical control object, a list of properties and their descriptions is included with the Help for the associated control directive. For example, a list of Button Properties is available by expanding the Help node for the BUTTON directive. For a list of Chart Properties, expand the Help node for the CHART directive, and so on. See Graphical Control Objects.

For quick access to the properties for a specific control type, use the links below:

 

Button

Grid

Radio_Button

Tree_View

 

Chart

List_Box

Report_View

Tristate_Box

 

Check_Box

List_View

Scrollbar (Horizontal)

Vardrop_Box

 

Drop_Box

Multi_Line

Scrollbar (Vertical)

Varlist_Box

For a list of all the properties on one page (in alphabetical order), see Properties List.

Note:
Different types of controls can also be created using NOMADS Panel Designer. For details on how to define a specific control type, see Creating Panel Controls.

See Also

Compound Properties
Color Properties

Using Property Names

Access to control object properties is provided via the Apostrophe Operator. An apostrophe operator (tick) allows dynamic access to the properties and methods available for a given COM, OOP or graphical object. Some properties are denoted with dollar signs to indicate that they represent string values; e.g. 'Msg$ or 'Tip$.

Example:

A button's location, size, text and color would be represented by properties named Height, Font$, Text$, TextColor$, etc. If the variable MyButton contained the CTL value associated with a button, you could change its text as follows:

MyButton'Text$="Hit me now"

Other common properties include:

Property

Description

'Col

Column

'Line

Line

'Cols

Width of the control

'Lines

Height of the control

'Tip$

Tip for the control

'Msg$

Message line for the control

'Fmt$

Format mask for the control

'TextColor$

Text Color

'Value$

Current value/state of the control

 

Note:
While programs can access or update property values, properties cannot be specified as the target for any file I/O or CALL parameter lists.

Generally, numeric properties are type insensitive; i.e. a property such as 'Line returns (or receives) a number. If desired, you can access the same value using the property 'Line$. This is also true for string properties, assuming that they only return numeric values.

Some properties return different values based on the type of reference you make. For example, most color properties return a text description of the RGB color when accessed as a string or a 24-bit color number when accessed as a numeric.

PxPlus also supports objects that are external to PxPlus (this section does not deal with the properties (and methods) that apply to them). See Apostrophe Operator.