Can't run sample applications in .NET 2005

yigalyigal Global Mapper UserPosts: 13
edited September 2008 in SDK
Hello,
I'd like to use the GlobalMapper SDK im my VB.NET 2005 applic, and therefore tried sample applications provided. I can get run only one of three sample applications, the VC++ 6.0 application. Neither sample application for VB or for C# runs. I have the same problem on both of them in run-time:
"Unable to load DLL 'GlobalMapperInterface': The specified module could not be found. (Exception from HRESULT: 0x8007007E)".

I've tried to "Add Reference" the "GlobalMapperInterface.dll" with no success, probably it's not a COM or NET object.

I've copied "GlobalMapperInterface.dll" and "GlobalMapperInterface.lib" in all folders from the root down to "Debug/Release" folders. No way they can be missed.

I've seen that there are "Declare"s in VB and "DllImport" in C# and thought it's enough.

What am I missing?

Thanks for your help
Yigal.

Comments

  • global_mapperglobal_mapper Administrator Posts: 17,238
    edited May 2008
    Yigal,

    You need to copy all of the files from the .bin folder of the SDK (with the exception of the GlobalMapperInterface.lib file) into the VB.NET and C# projection folders (I'm honestly not 100% sure which folder under the project) to get the GlobalMapperInterface.dll file to load. It depends on most of those DLLs to load, so if they are missing it will fail to load.

    Let me know if I can be of further assistance.

    Thanks,

    Mike
    Global Mapper Support
    support@globalmapper.com
  • yigalyigal Global Mapper User Posts: 13
    edited May 2008
    Thanks a lot! It's working.:)
  • hany m. magdyhany m. magdy Global Mapper User Posts: 15
    edited September 2008
    i have also an error in Visual Studio 2005 CSharp 'An attempt was made to load a program with an incorrect format. (Exception from HRESULT: 0x8007000B)' i have version SDK 10
  • global_mapperglobal_mapper Administrator Posts: 17,238
    edited September 2008
    You do NOT want to try and add the GlobalMapperInterface.dll file to your project as it is not a DLL that you can embed in the projection as its not an ActiveX control or anything like that. Rather you just declare your functions as coming from the GlobalMapperInterface.dll file and it will load automatically at run time.

    There is a small C# sample application demonstrating how to do this on the Developers page at GLOBAL MAPPER.

    Let me know if I can be of further assistance.

    Thanks,

    Mike
    Global Mapper Support
    support@globalmapper.com
  • hany m. magdyhany m. magdy Global Mapper User Posts: 15
    edited September 2008
    I tried sample on windows xp 32 bit and working fine but on my vista 64 bit it shown this error 'An attempt was made to load a program with an incorrect format. (Exception from HRESULT: 0x8007000B)'

    and somethig else i need a documentation for the SDK, the document with sdk is just refernce for the functions.
  • global_mapperglobal_mapper Administrator Posts: 17,238
    edited September 2008
    Are you trying to build a native 64-bit application using the Global Mapper SDK? The SDK is currently only available as a 32-bit library and cannot be used in a 64-bit application. We are working on a 64-bit version of the SDK for release later this year though.

    Thanks,

    Mike
    Global Mapper Support
    support@globalmapper.com
Sign In or Register to comment.