Our application is C# .Net 4 and calls an unmanaged 32bit DLL. It's been working fine and runs many machines (mostly 64bit Windows 7). However, I recently encountered one particular user on whose machine the program traps with BadImageFormatException as soon as the call into the unmanaged DLL is made.
BadImageFormatException: An attempt was made to load a program with an incorrect format. (Exception from HRESULT: 0x8007000B)
I've done the following:
- Ensured the install and files are correct
- Matched his .Net runtime updates as closely as possible to working machines
- Ensured all projects' platform target are set to x86
- Run a debug build, which works
I'm nearing my wit's end. Any suggestions? Is there a particular .Net 4 update or hotfix the lack of which cause this type of issue?