$gui

Return the mnemonic (CHR or MSW) for the user interface.

$gui

Example: if ($gui="CHR") ...

Return Values

Values returned by $gui
Value User interface
CHR Character mode
MSW Microsoft Windows

Use

Use in Form components.

Description

The value returned by$gui is the same as that specified by the assignment file setting $GUI.

Note:  You cannot use $gui to determine which version of Windows is running. Use $oprsys to determine the operating system mnemonic.

Dynamically Setting Command Button Appearance

The following example uses $gui to determine whether to load an image file into a command button, or to display text instead:

operation exec
; In character mode ?
; Yes, so display text only
; No, so load picture

if ($gui = "CHR")
   BUTTON1 = "Picture of Jim"
else
   BUTTON = "@jim"
endif
edit
end; exec

Related Topics