Little help please.

BlitzPlus Forums/BlitzPlus Programming/Little help please.

hmmm, check this out!

Global MainProgBar, SecProgBar, MainWindow

WinWidth = 400
WinHeight = 100
MainWindow = CreateWindow("testapp",GadgetWidth(Desktop())/2-(WinWidth/2),GadgetHeight(Desktop())/2-(WinHeight/2),WinWidth,WinHeight,0,1+8)
MainProgBar = CreateProgBar(3,4,WinWidth-12,20,MainWindow)
SecProgBar = CreateProgBar(3,25,WinWidth-12,20,MainWindow)

Repeat
	If KeyDown(1) Then crap=1
	x = x + 1
	If x > 10000000 Then x=0:myprogress1# = myprogress1#+.01:UpdateProgBar(SecProgBar,MyProgress1#)
	
Until myprogress1#>1
end


Run that and switch between different apps.. everything should appear normal.

Now commet out the following line
;If KeyDown(1) Then crap=1


And try it again! Now when you switch between apps, nothing comes back!!!!

There you go mordax, just put some realworld input in without it doing anything important!