Home iWeb Logon Internet Meetings Contact Us Site Map

Z Programs

Z.choice.list


Arguments        A = ^file of choices, consisting of choice text and 1-2 letter mnemonics.
subscript is the display.order
See arg E for file structure of text and mnemonics
B = default mnemonics

; optional arguments:
C = Q(R,C,@center) = where to put window (dft is "field-based")
IF{C|2 @CENTERED.WINDOW;@WINDOW.AT.R.C}
D = title (default is "CHOICES")
E - address of mnemonic and text:
E|0 = Address of mnemonic:
If "" - use subscript of file as the mnemonic
else E|0 is the packed piece where the mnemonic is stored.
E|1 = Address of text:
If "" - use value of file, ie, [A,sub]
else E|1 is the packed piece where the name is stored.
Thus if E = Q("",""), file structure is [A,mnemonic]=text
if E = Q(0,1),   file structure is [A,display.order]=Q(mnemonic,text)
Returns option.letter or nil

Example call:    %Z.choice.list(^/CH,2,Q("","",1),"Title",Q("",1))
Given structure: /CH[1]=Q(5,”Five”)
                        /CH[2]=Q(4,”Four”)
                        /CH[3]=Q(3,”Three”)
                        /CH[4]=Q(2,”Two”)
                        /CH[5]=Q(1,”One”)
                        /CH[6]=Q(0,”Blastoff”)
   

Posted: August 03, 2001

Return to list of Z Programs