help window

BlitzPlus Forums/BlitzPlus Programming/help window

Try this:
mainwin=CreateWindow("main",200,200,400,300,0,3)
helpwin=CreateWindow("help",150,80,100,80,0,3)
ActivateGadget mainwin

quit=False

Repeat
 ev=WaitEvent()
 Select ev
  Case $803
   If EventSource()=mainwin
    If helpwin<>0 FreeGadget helpwin
    FreeGadget mainwin
    quit=True
   EndIf
   If EventSource()=helpwin
    FreeGadget helpwin : helpwin=0
   EndIf
 End Select
Until quit=True

End