Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

0xc000007b Error?

here is some information to understand my situation better.

OS: windows 8.1

IDE: Visual Studio 2008 Pro

Language: C++

i have just my Firefox reinstalled and after this(maybe it was not the reason),

my visual studio Project compiled only with 9.0.30729.6161 VC++ Runtime DLL.

Until yesterday it always compiled with 9.0.30729.8387 VC++ Runtime DLL.

Because of this (or maybe other reason), now i cannot start my Project.exe.

Nothing is changed in source-code. Project-Property and all other things are also unchanged.

I just get the error number 0xc000007b suddenly.

How can i fix this?

error message

like image 577
jung Avatar asked Feb 03 '15 12:02

jung


People also ask

What causes 0xc00007b error?

Reasons of Windows error code 0xc000007b The error code means an invalid image format. Specifically, you are attempting to start an application which is designed to run on 64-bit operating system. But your computer is running 32-bit Windows.


2 Answers

It was because of an 32bit DLL, which should not be loaded for my 64bit Project.exe.

I have found this with Process Monitor.

I don't know why, but anyway is the "path" is changed and the 32bit DLL(which has the same name with 64bit DLL) is loaded..

If you have the same Problem, check whether there is a problem between your application and its dependencies using dependency walker.

like image 87
jung Avatar answered Sep 23 '22 00:09

jung


Entered the answer in another place, but figure it could be helpful for folks who badly need some help:

It has been mentioned in other answers that using dependency walker is the way to go, in my case (my application keeps failing with the error code), dependency walker showed a few dll that are NOT relevant!

Finally figured out that I can run profiling by going to "profile" menu and it will run the application and stop at the exact dll that's cause the problem! I found out a 32bit dll was picked because of path and fixed it.

enter image description here

like image 27
pktCoder Avatar answered Sep 25 '22 00:09

pktCoder