Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / Hey what is the exit code? The alternative for the esc key

Author
Message
The Lone Programmer
21
Years of Service
User Offline
Joined: 29th Jan 2003
Location: California, USA
Posted: 14th Feb 2003 07:25
I thought I had an idea of what the code was for exiting out of something but I guess I was wrong.

Will someone please post the code for the exit option.
If there are different kinds of exit code please list all you know.

Thanks
SmokieMcPot
Future Company Name = Blazing Fire
Current Website Name = Blazing Fire
Future Number is Eleventy
large_nostril
21
Years of Service
User Offline
Joined: 5th Feb 2003
Location: United States
Posted: 14th Feb 2003 08:37
If you want to stop the esc key from exiting the program, then do this type in this line of code

Now you can use make your own function to exit your program. i.e.

this is saying if the [esc] button is pushed, then the program will exit(END is the function to terminate the program). You can change the key that induces the exit by using a different KEYSTATE() value. You can also add in a confirmation dialog, etc.
Hope this helps.

If you want fresh underwear in the morning, take it off the night before.
The Lone Programmer
21
Years of Service
User Offline
Joined: 29th Jan 2003
Location: California, USA
Posted: 14th Feb 2003 16:39
Thanks for trying to help but that is not what I meant.

I have a menu with an exit button on it. The menu is controlled by mouseclicks. I have goto's in my code and that seems to be throwing off the exit code. I had something like this

if mouseclick()=1 then exit

It doesnt seem to be working in my code now. It appears to says whatever I have in my goto code.

Thanks
SmokieMcPot

Future Company Name = Blazing Fire
Current Website Name = Blazing Fire
Future Number is Eleventy
Arrow
21
Years of Service
User Offline
Joined: 1st Jan 2003
Location: United States
Posted: 14th Feb 2003 19:07
Insted of Exit, use End

Am I a butterfly dreaming I'm a man?
Or a bowling ball dreaming I'm a plate of samishi?
Never assume that what you see or feel is real.
John H
Retired Moderator
21
Years of Service
User Offline
Joined: 14th Oct 2002
Location: Burlington, VT
Posted: 14th Feb 2003 22:40
Yea, I got to him in his other post

Current - RPG: Eternal Destiny : Help Wanted!
http://www.halbrosproductions.netfirms.com
Dont ask those questions! Read the help files lazy!

Login to post a reply

Server time is: 2024-09-19 18:03:27
Your offset time is: 2024-09-19 18:03:27