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.

DarkBASIC Discussion / Where DBClassic Compiles Executable

Author
Message
Sonic Spindash
17
Years of Service
User Offline
Joined: 6th Nov 2008
Location:
Posted: 6th Nov 2008 21:06
When DarkBASIC Classic compiles and executes your code, where does it store that executable file?

I've run into a strange problem where different code files will all execute the same file, i.e. it doesn't matter what code is open, when I hit Run > Execute it runs that original file.

I believe it stems from a Windows permissions issue, where my log in doesn't have the correct rights to write to the file where the code executable is stored, and defaults to the original one written there (possibly when I did have the rights).

Working on Toshiba Laptop Windows Vista Business SP1
Intel Core Duo 1.73x2
1 Gig Ram
Intel Integrated 945 graphics family chipset

Running rings around you.
Latch
19
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 7th Nov 2008 08:15 Edited at: 7th Nov 2008 08:21
Hello,

It sounds like you are using the default editor. Have you tried saving your programs before running them?

Also, try DarkEDIT. It is a much better editor. You can also choose specifically where things are stored (in fact you have to set it up before you run it).

DarkEDIT

And maybe I'm misunderstanding, are you talking about creating a stand alone exe file or running the code in the current window?

The exe file is usually created in the main folder of your project. And you have to go to the folder itself and launch that as it's own application outside of darkbasic. You can't launch a stand alone exe file from within the DarkBASIC editor.

DarkBASIC Classic scripts are never really compiled per se. They are interpreted. When you run a script in the window, that script is run through the interpreter - that's why I think it may have to be saved first in the default editor - but the tutorials should run without a problem because they are already saved. Even when you make a stand alone exe file, the interpreter is built into your program file.

Enjoy your day.
Sonic Spindash
17
Years of Service
User Offline
Joined: 6th Nov 2008
Location:
Posted: 18th Nov 2008 21:27
Hello Latch!

Thanks for your clarification. Indeed I meant where the code was "interpreted" and am using the original editor. I believe I found the solution to the problem. Normally, as administrator on your computer, you will never have this problem. However, with a restricted log in, the needed rights may be turned off, thereby causing a strange problem where opening different code files all execute the same code (coincidentally, the last code file executed on the admin account).

DBC v1.13 requires permission to write to the C:\WINDOWS\Temp folder (in addition, the new version, DBC v1.21, instead writes to the C:\dbTemp folder). If the restricted log in doesn't have the correct rights, you will get the same code problem. In either case, you need to edit a "Special Permission" for writing to these folders.

As administrator, right click your C:\dbTemp folder (or your C:\WINDOWS\Temp folder if running DBC v1.13) > click 'Properties' > then click the 'Security' tab. Make sure the restricted log in has "Read" and "Read & Execute" permissions.

Now, click "Advanced" to enter the "Special Permissions" editor. Find the "Create Files/Write Data" entry and click "Allow." Now the restricted log in will be able to write to the folder when executing the code.

In short, a VERY specific fix to a VERY specific problem.

Running rings around you.
Latch
19
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 2nd Dec 2008 19:18
Glad you solved it! And the fix should be helpful to others!

Enjoy your day.

Login to post a reply

Server time is: 2026-07-05 06:00:33
Your offset time is: 2026-07-05 06:00:33