Page 1 of 1

Cannot execute the file with the internal debugger

Posted: Wed Mar 13, 2024 7:45 pm
by charvista
Hello,
Today I have a strange problem.
I am coding and press the F5 button to run it (with a Debug to test it).
At runtime, it stops with the message: "Cannot execute the file with the internal debugger. Please try the standalone one."
I don't remember to have changed anything in the settings....
What is happening here? How to reset this? :?

Re: Cannot execute the file with the internal debugger

Posted: Wed Mar 13, 2024 8:02 pm
by mk-soft
Wrong compiler selected on compiler options ?

Re: Cannot execute the file with the internal debugger

Posted: Wed Mar 13, 2024 8:10 pm
by Justin
I think i had the same problem, try disabling windows defender

Re: Cannot execute the file with the internal debugger

Posted: Wed Mar 13, 2024 8:22 pm
by charvista
I think i had the same problem, try disabling windows defender
You are right Justin, I disabled the real protection of Windows Defender, and it worked again.
Now, how to add an exception for PureBasic ?

Re: Cannot execute the file with the internal debugger

Posted: Wed Mar 13, 2024 9:13 pm
by charvista
Ok, I found that I could add an exclusion:
Folder C:\Users\<username>\AppData\Local\Temp
Then it works.
*BUT* this is dangerous, because many programs are using this folder, so malwares can run anything there.

PureBasic 6.10 should add a sub-folder, so the execution is done in a very specific PureBasic folder,
for example C:\Users\<username>\AppData\Local\Temp\PureBasic\

Question : Can I modify myself the location where PureBasic may run when pressing the F5 key?

Re: Cannot execute the file with the internal debugger

Posted: Wed Mar 13, 2024 9:20 pm
by mk-soft
Compiler Option -> Compile/Run or Preferences -> Compiler -> Defaults
* Create temporary executable in the source directory

Added your scource base folder to an exclusion ...

Re: Cannot execute the file with the internal debugger

Posted: Wed Mar 13, 2024 9:49 pm
by charvista
mk-soft wrote: Wed Mar 13, 2024 9:20 pm Preferences -> Compiler -> Defaults
[Check] Create temporary executable in the source directory
Even doing so, the PureBasic_Compilation0.exe is still done in c:\Users\<username>\AppData\Local\Temp\
What is the "source directory"? Is that where my program is located at runtime? I see nothing there.

Re: Cannot execute the file with the internal debugger

Posted: Wed Mar 13, 2024 10:15 pm
by mk-soft
The default setting is used for new files. Existing files must be set subsequently in Compiler Option -> Compile/Run.

Re: Cannot execute the file with the internal debugger

Posted: Wed Mar 13, 2024 10:56 pm
by charvista
I got it. It works again well.
Thank you for your very valuable help!
Cheers