WBStartup
WbToScreen 3
Use Screen 3

LoadFont 2,"garnet.font",9
Use IntuiFont 2


; DONT USE COMMANDS WHICH USE A3 AS A PARAMETER DIRECTLY WITH HEX$
; COS IT GOES SCREWY


foo.l=GTCycle(0,1,70,20,150,15,"Cycle-me-do!",#PLACETEXT_RIGHT,"foo|bar|snafu")
NPrint Hex$(foo)

GTButton 0,2,20,40,250,15,"Change cycle options",#PLACETEXT_IN

AddIDCMP #CYCLEIDCMP|#BUTTONIDCMP

Window 0,0,0,400,300,$100f,"jjlk",-1,-1
DefaultOutput
CatchDosErrs

Dim option$(2)
option$(0)="this|is the|first|changed|set of|options|and it's|quite|long|as you|can see"
option$(1)="final one|a bit shorter|you like?"

optset.w=0

; Test of the GTChangeCycle command when not attached to a window
GTChangeCycle 0,1,"eat|my|shorts"

AttachGTList 0,0
While ev.l<>#IDCMP_CLOSEWINDOW
    ev.l=WaitEvent
    Select ev
        Case #IDCMP_GADGETUP
            If GadgetHit=2
                If optset<2
                    GTChangeCycle 0,1,option$(optset)
                    optset = optset+1
                Else
                    dummy.l=RTEZRequest("GTChangeCycle example","No more option strings to demo","OK")
                EndIf
            EndIf
    End Select
Wend
DetachGTList 0
End


