ProvideX V8.20 > Language Reference > 2. Directives
177
LIST_BOX Directive
         Control List Box
Formats
1.Define/Create: LIST_BOX ctl_id,@(col,ln,wth,ht)[,ctrlopt]
Includes Formatted, List View, Report View, and Tree View list box formats.
2.Remove: LIST_BOX REMOVE ctl_id[,ERR=stmtref]
3.Disable/Enable: LIST_BOX {DISABLE | ENABLE} ctl_id[,ERR=stmtref]
4.Hide/Show: LIST_BOX {HIDE | SHOW} ctl_id[,ERR=stmtref]
5.Force Focus: LIST_BOX GOTO ctl_id[,ERR=stmtref]
6.Signal on Focus: LIST_BOX SET_FOCUS ctl_id,alt_ctl,[,ERR=stmtref]
7.Load via Delimited String: LIST_BOX LOAD ctl_id,dlm_list$[,ERR=stmtref]
8.Load Via Array: LIST_BOX LOAD ctl_id,array_name${ALL}[,ERR=stmtref]
Note: The curly braces enclosing {ALL} are part of the syntax.
9.Load/Delete Index Element: LIST_BOX LOAD ctl_id,index,{element$ | *}[,ERR=stmtref]
10.Find Element: LIST_BOX FIND ctl_id,index,var$[,ERR=stmtref]
11.Read Current Selection: LIST_BOX READ ctl_id,var$[,mode$][,ERR=stmtref]
12.Read Current Index: LIST_BOX READ ctl_id,var[,mode$][,ERR=stmtref]
13.Write Current Selection: LIST_BOX WRITE ctl_id,element$[,ERR=stmtref]
14.Write Current Index: LIST_BOX WRITE ctl_id,index[,ERR=stmtref]
15.Clear Current Selection: LIST_BOX WRITE ctl_id, ""[,ERR=stmtref]
16.Report All Changes: LIST_BOX AUTO ctl_id[,ERR=stmtref]
Where:
@(col,ln,
Position and size of the list box region. Numeric expressions. Column
wth,ht)
and line coordinates for top left corner, width in number of columns
and height in number of lines.
alt_ctl
CTL value to generate when the list box gains focus.
array_name$ Name of array to load into list box. String variable followed by {ALL}.
ctl_id
Unique logical identifier for the list box (any integer -32000 to +32000).
Avoid integers that conflict with keyboard definitions (e.g., 4 cancels
CTL=4 for the F4 key) or Negative CTL Definitions, p.822. Use this
value with the apostrophe operator to access various Dynamic
Properties.
Control options. Supported options for LIST_BOX include:
ctrlopt
ERR=stmtref Error transfer
FMT=def$ Define more elaborate List Box Styles, p.181.
FNT="font,size[,attr]" Font name, size, optional properties
Refer to the 'FONT' Mnemonic, p.607 for more details.
KEY=char$ Hot key
MNU=ctl CTL value associated with right-click menu event.
MSG=text$ Message line