Page 1 of 1

My program is not running from an .exe

Posted: Wed Apr 10, 2019 11:21 pm
by stevylake
Hello.

So I am pulling my hair out just now. A program will run from the IDE
Compiler > Run

But if I create an .EXE of the program it creates it alright but refuses to run. No windows error. Just a quick spin on the timer and nothing.

Help!

Thanks.

Re: My program is not running from an .exe

Posted: Wed Apr 10, 2019 11:32 pm
by Jeff88
Does your program depend up which directory it is running?

Put this line in the beginning of the program to show its directory.

Debug GetPathPart(ProgramFilename())

Re: My program is not running from an .exe

Posted: Wed Apr 10, 2019 11:42 pm
by stevylake
Jeff88 wrote:Does your program depend up which directory it is running?
It is a stand alone utility that uses no outside files. In any case I have tried compiling to the same directory as the source files.

Re: My program is not running from an .exe

Posted: Thu Apr 11, 2019 12:00 am
by stevylake
Solved but a quirky bug.

So I saved the program but with an old icon file. Everything worked. I then set the icon to use to be a new one and created the .exe file again but with the same .exe name. The logo didn't change to the new one and it wouldn't run. I changed the name to something else and it created the .exe with the correct logo and ran! Oh dear. Time for bed!!