Posts: 19
Threads: 7
Joined: Jul 2003
is there a reason y wen i mke a shape program y once i compile it and run it it automatically closes right once it loads. it does it so fast i cant even view it. why does it do that?? here is the code.
Quote:Cls
Screen 1
Circle (120, 52), 25, 5
Circle (75, 105), 25, 5
Line (21, 73)-Step(100, 0.5)
Line (75, 74)-Step(101, 0.5)
Print "blah blah"
i was just experimentin with the code it dosnt actualy make anything i just wanted to try it but y does it just close out??
Posts: 1,556
Threads: 298
Joined: Dec 2002
It closes out because it's done... nice you're new to this, just try SLEEP, it'll work for now, but later when you learn about using keys, you'll need to take a step away from that...
Posts: 19
Threads: 7
Joined: Jul 2003
ok so i added sleep at then end of the code liek this:
Quote:Cls
Screen 1
Circle (120, 52), 25, 5
Circle (75, 105), 25, 5
Line (21, 73)-Step(100, 0.5)
Line (75, 74)-Step(101, 0.5)
Print "blah blah"
SLEEP
and an error came up... am i supose to use the sleep command differnetly?? if so can u show me an example??
Posts: 3,343
Threads: 83
Joined: Mar 2003
Code:
CLS
Screen 1
Circle (120, 52), 25, 5
Circle (75, 105), 25, 5
Line (21, 73)-Step(100, 0.5)
Line (75, 74)-Step(101, 0.5)
Print "blah blah"
WHILE INKEY$ <> "": WEND
WHILE INKEY$ = "": WEND
That should do it. (untested)
Posts: 19
Threads: 7
Joined: Jul 2003
that worked great thank u
and also i would like to point out how fast people will anser ur questions in this forum i think its great in many others u have to wait a while but in this i get it right after i post it . thnks
Posts: 358
Threads: 15
Joined: May 2003
Quote:is there a reason y wen i mke a shape program y once i compile it and run it it automatically closes right once it loads. it does it so fast i cant even view it. why does it do that??
Another suggestion...if you run the program from a DOS window it won't close when finished.