Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

"The application failed to initialize properly (0xc000007b)."

I get this error when i try to start a program that I've made in C++. It works fine on my other computer (XP SP3 32bit) but not on my windows 7 64 bit version. When I run Dependency Walker on the program, it tells me that IESHIMS.dll is missing, however it's there in the Internet Explorer folder of both 32 and 64 bit version..

Can anyone help me with this?

like image 825
lordstyx Avatar asked Jul 31 '10 14:07

lordstyx


1 Answers

The error code is STATUS_INVALID_IMAGE_FORMAT, "Mumble is either not designed to run on Windows or it contains an error. Try installing the program again using the original installation media or contact your system administrator or the software vendor for support."

Which is a bit outdated perhaps for the 64-bit version of Windows, the 90% odds are that your 32-bit program is trying to load a 64-bit DLL. There's a lot that Windows does to prevent that from ever happening. File system virtualization ensures that DLL loads from c:\windows\system32 are redirected to c:\windows\syswow64, home of the 32-bit DLLs. Registry virtualization ensures that COM servers are matched with the bit-ness of the COM client.

There's something you do that bypasses these counter-measures. Maybe you used SetDllDirectory(). Or you copied DLLs to the same folder as your EXE. Or you are hoping that the system's PATH environment variable helps your program find the right DLL. Something like that, it isn't otherwise clear from your question. There ought to be a record of it in the Windows event log (not 100% sure). If all else fails, SysInternals' ProcMon utility can show you what file it is trying to load.

like image 59
Hans Passant Avatar answered Nov 04 '22 09:11

Hans Passant