Visualizations such as edit box, spin edit box, track bar and progress bar return the value specified in the visualization as usual.
However, visualizations based on picklists return the value specified in the Value parameter of the selected picklist item.
This form shows how the Example Spin Edit Box and the example List (based on picklist) return their value:
Here is the form source:
Function Options(*DIRECT)
BEGIN_COM ROLE(*EXTENDS #PRIM_FORM) CLIENTHEIGHT(189) CLIENTWIDTH(637) HEIGHT(227) LEFT(437) TOP(222) WIDTH(653)
DEFINE_COM CLASS(#SIZE.Visual) NAME(#SIZE) DISPLAYPOSITION(2) LEFT(24) MARGINLEFT(100) PARENT(#COM_OWNER) TABPOSITION(2) TOP(64) WIDTH(201)
DEFINE_COM CLASS(#STD_TEXTS.Visual) NAME(#STD_TXT_1) CAPTION('Value of #Size:') DISPLAYPOSITION(1) HEIGHT(19) LABELTYPE(Caption) LEFT(256) MARGINLEFT(120) PARENT(#COM_OWNER) TABPOSITION(1) TOP(72) USEPICKLIST(False) WIDTH(217)
DEFINE_COM CLASS(#STD_TEXTS.Visual) NAME(#STD_TXT_2) CAPTION('Item Caption of #Size:') DISPLAYPOSITION(3) HEIGHT(19) LABELTYPE(Caption) LEFT(256) MARGINLEFT(120) PARENT(#COM_OWNER) TABPOSITION(3) TOP(96) USEPICKLIST(False) WIDTH(217)
DEFINE_COM CLASS(#SALARY.Visual) NAME(#SALARY) DISPLAYPOSITION(4) LEFT(24) MARGINLEFT(100) PARENT(#COM_OWNER) TABPOSITION(4) TOP(24) WIDTH(201)
DEFINE_COM CLASS(#STD_COUNT.Visual) NAME(#STD_COUNT) CAPTION('Value of #Salary:') DISPLAYPOSITION(5) HEIGHT(19) LABELTYPE(Caption) LEFT(256) MARGINLEFT(120) PARENT(#COM_OWNER) TABPOSITION(5) TOP(28) USEPICKLIST(False) WIDTH(217)
Evtroutine Handling(#SALARY.Changed) Options(*NOCLEARMESSAGES *NOCLEARERRORS)
Change Field(#STD_COUNT) To(#SALARY)
Endroutine
Evtroutine Handling(#SIZE.Changed) Options(*NOCLEARMESSAGES *NOCLEARERRORS)
Change Field(#STD_TXT_1) To(#SIZE)
Change Field(#STD_TXT_2) To('#SIZE.text')
Endroutine
End_Com
A check box visualization returns the value of the first picklist item if the check box is not ticked, and the value of the second picklist item when the check box is ticked.
This form shows the value of the example Check Box:
Here is the source for the form:
Begin_Com Role(*EXTENDS #PRIM_FORM) Caption('Test Form') Height(139) Left(414) Top(164) Width(421)
Define_Com Class(#HEALTHFND.Visual) Name(#HEALTHFND) Displayposition(1) Left(19) Parent(#COM_OWNER) Tabposition(1) Top(47)
Define_Com Class(#STD_TEXTS.Visual) Name(#STD_TEXTS) Caption('Value of #HEALTHFND:') Displayposition(2) Height(19) Labeltype(Caption) Left(216) Parent(#COM_OWNER) Tabposition(2) Top(48) Width(185)
Evtroutine Handling(#HEALTHFND.Changed) Options(*NOCLEARMESSAGES *NOCLEARERRORS)
Change Field(#STD_TEXTS) To(#HEALTHFND)
Endroutine
End_Com