
    'locate.bas
    'This program demonstrates how to change the location
    'of a control in a window.
    combobox #main.lb, array$(), [ok], 10, 10, 100, 150
    open "Locate control" for window as #main
    print #main, "trapclose [quit]"

    for x = 10 to 200 step 10

        call pause
        'relocate the combobox
        print #main.lb, "locate ";x; " ";x; " 100 150"

        'force the new location to take effect
        print #main, "refresh"

    next x

    wait

[quit]
    close #main
    end

sub pause    'pause for a tenth of a second

    start = time$("ms")
    while start + 100 > time$("ms")
    wend

end sub
