8

I have written a pretty simple C# Windows Forms application, and a colleague wants to test it out on Windows 7 using Parallels 8, because he only has a Mac.

The problem is, when he starts it up using the EXE file in the debug folder, he gets this error:

Error starting OMAPI (Unable to load DLL 'libomapi.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E)) Check the required .dll files are present the correct versions: OmApiNet.dll libomapi.dll

As you can see from the image below, the required DLL files are right there in the same folder, and if he takes this debug folder to a Windows PC it works fine, so it's definitely some sort of virtual machine or Parallels-specific problem.

Screenshot of error

How can I fix this problem?

I haven't really used virtual machines enough to know what the problem could be...

10
  • 4
    What format is the executable versus the libraries? Given it's IN the same folder it should find it so I'm wondering if it's really a bad format problem (32-bit vs 64-bit)?
    – Lloyd
    Mar 21, 2013 at 18:01
  • 2
    You might also find it's an external dependancy problem, something on your parallels setup doesn't exist that does on your other setup, try using Dependency Walker - dependencywalker.com
    – Lloyd
    Mar 21, 2013 at 18:06
  • 7
    I've seen some funny things happen if the project is compiled for AnyCPU but a dependent library is x86 and the destination OS is x64. Mar 21, 2013 at 18:06
  • 1
    Make sure all your dependend DLLs and your application are built with the same processor architecture (x86 or x64). Stay away from AnyCPU with virtual machines.
    – qJake
    Mar 21, 2013 at 20:01
  • (Sorry for the late reply been away) Ah okay, I'll ask him what his Parallels setup is and I'll recompile with x86/x64 rather than AnyCPU and report back. Thanks all for the help so far.
    – poncho
    Apr 5, 2013 at 13:26

3 Answers 3

0

it'd be interesting to run ProcMon on it and see what it's really doing to try and find the files.

0

This is possibly more of a network drive issue. Have him copy that folder from the Y: drive (shared from his Mac) to the C: drive and run it again from there.

0

It looks like your trying to run the application from a network share, in which the .NET platform forbids as its a security risk. Try copying the files to someplace else on the virtual machine such as C:\Temp.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.