' createwindow.bmx Import MaxGui.Drivers Strict Local window:TGadget Local full:tgadget Local minimize:tgadget,special:tgadget window=CreateWindow("My Window",40,40,320,240) full = CreateButton("FULL" , 10 , 10 , 80 , 20 , window) minimize = CreateButton("MINIMIZE" , 10 , 30 , 80 , 20 , window) special = CreateButton("SPECIAL" , 10 , 50 , 80 , 20 , window) While True WaitEvent Print CurrentEvent.ToString() Select EventID() Case EVENT_GADGETACTION Select EventSource() Case special Print window.xpos Print window.ypos window.width = 200 window.height = 400 window.Rethink() Case full MaximizeWindow window Case minimize MinimizeWindow window End Select Case EVENT_WINDOWCLOSE End End Select Wend