Code::Blocks Forums

User forums => Help => Topic started by: igdegoo on December 28, 2017, 05:53:08 pm

Title: Strange error when running my program
Post by: igdegoo on December 28, 2017, 05:53:08 pm
(http://i.cubeupload.com/kjofwE.png)
I have no idea why this pops up.
When I run in the Code::Blocks editor it runs fine, but when I run the .EXE from the file explorer I get that message.
I am using MinGW compiler.

I can post the source code if it is required.
Title: Re: Strange error when running my program
Post by: oBFusCATed on December 28, 2017, 06:20:04 pm
It is either a missing dll or mismatched dll. Use dependency walker to find which of the two is...
Title: Re: Strange error when running my program
Post by: igdegoo on December 28, 2017, 06:41:06 pm
It is either a missing dll or mismatched dll. Use dependency walker to find which of the two is...
What is dependency walker?
Title: Re: Strange error when running my program
Post by: oBFusCATed on December 28, 2017, 07:15:25 pm
http://bfy.tw/Uww
Title: Re: Strange error when running my program
Post by: igdegoo on December 29, 2017, 04:21:15 pm
http://bfy.tw/Uww
thanks, it works now
do you know how to compile it without it requiring all these DLLs?
Title: Re: Strange error when running my program
Post by: igdegoo on February 22, 2018, 03:56:37 pm
i still don't know know how to compile it without it requiring all these DLLs
Title: Re: Strange error when running my program
Post by: stahta01 on February 22, 2018, 05:24:56 pm
i still don't know know how to compile it without it requiring all these DLLs

I suggest asking on a site the supports the compiler.
The normal way is to use static library instead of a shared/DLL library.

Tim S.
Title: Re: Strange error when running my program
Post by: BlueHazzard on February 22, 2018, 07:12:38 pm
Quote
I suggest asking on a site the supports the compiler.
Or the site that supports the library. You don't tell us what library so we can not say how to link it statically
Title: Re: Strange error when running my program
Post by: BentL on March 13, 2018, 01:21:27 pm
When I run in the Code::Blocks editor it runs fine, but when I run the .EXE from the file explorer I get that message.

The reason you get this error is because your exe-file cannot find the necessary dynamic link libraries. You either have to include these in the same folder as the exe-file, or you can specify that all libraries should be statically linked to the exe-file, so the application contains just one file:

File > Project > Build options... > Select application name > Linker settings > Other linker options > -static