'Neotrek Software


//cut and paste


//for free use with gfa basic


'Advanced Example 3 test api command windget


'Discussion: polling WindGet() api parameters.


Global parm&

Global a%


'If you are programming a project with multiple

'GFA windows #(handle 0-31) this should be helpful

'once the parameters are polled decisions can be

'made about the window.


Dim WPara$(19)

WPara$(0) = " 0 outer X-coordinate"

WPara$(1) = " 1 outer Y-coordinate"

WPara$(2) = " 2 outer width"

WPara$(3) = " 3 outer height"

WPara$(4) = " 4 inner X-coordinate"

WPara$(5) = " 5 inner Y-coordinate"

WPara$(6) = " 6 inner width"

WPara$(7) = " 7 inner height"

WPara$(8) = " 8 *WSET position of vertical slider (0..1000)"

WPara$(9) = " 9 *WSET size of slider area"

WPara$(10) = "10 *WSET position of horizontal slider (0..1000)"

WPara$(11) = "11 *WSET size of slider area"

WPara$(12) = "12 window attributes set with OPENW"

WPara$(13) = "13 *WSET attributes of pressed window button"

WPara$(14) = "14 character height (for example 8, 14, 16)"

WPara$(15) = "15 character set address"

WPara$(16) = "16 number of top window"

WPara$(17) = "17 number of second to top window"

WPara$(18) = "18 number of second to bottom window"

WPara$(19) = "19 number of bottom window"

//The asterisk indicates which parameters can be changed

//with WINDSET.

AutoRedraw = True

OpenW 1, 20, 20, 400, 400, -1

Dim wget_par&(19)

TitleW 1, "Parameters for this Gfa basic window"

For parm& = 1 To 19

a% = wget_par(parm&)

WindGet parm&, a%

Text.04 * _X, .04 * parm& * _Y, WPara$(parm&) + " =" + Str(a%)

Next parm&

KeyGet a%

CloseW 1