Hi
I made this small example to show you what my problem is:
startBlue "",""
sync off
global Main
global Window
global Edit
global Button
hey=1
Main=createMenu(0)
Window=createWindow(0,0,120,120,"Hi",WINDOW_NORMAL,0,0,Main)
Edit=createEdit(0,0,100,25,0,window)
Button=createButton(30,30,60,25,"exit",0,window)
do
getEvent
if eventSource()=Window
if eventType()=WINDOW_CLOSE
end
endif
endif
if eventSource()=Button
if eventType()=MOUSE_CLICK
end
endif
endif
setGadgetText Edit,str$(hey)
sync
loop
In this program the "Exit"-button won't work, neither can you exit by pressing the X in the corner.
However :
startBlue "",""
sync off
global Main
global Window
global Edit
global Button
hey=1
Main=createMenu(0)
Window=createWindow(0,0,120,120,"Hi",WINDOW_NORMAL,0,0,Main)
Edit=createEdit(0,0,100,25,0,window)
Button=createButton(30,30,60,25,"exit",0,window)
do
getEvent
if eventSource()=Window
if eventType()=WINDOW_CLOSE
end
endif
endif
if eventSource()=Button
if eventType()=MOUSE_CLICK
end
endif
endif
sync
loop
this program works. I only removed the "SetGadgetText" from the loop.
Can anyone help me?
Thanks
KLU 007