Infrastructure Map Server Developer

Infrastructure Map Server Developer

Reply
Active Member
georgega
Posts: 7
Registered: ‎11-18-2009
Message 1 of 4 (1,814 Views)

Error - Could not load file or assembly MapGuideDotNetAPI

1814 Views, 3 Replies
12-30-2011 02:35 PM

I'm trying to embed an AIMS 2012 viewer in a webpage. I'm following the instructions in Daniel Du's webcasts. It doesn't matter if I embed a basic layout or a flex layout. I get the same error message when I try to browse the page - "Could not load file or assembly 'MapGuideDotNetApi, Version=2.3.0.4202, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format."

 

I found some references to this error on the OSGeo website for MapGuide OS but not sure if it applies to AIMS 2012. I know that the dll referenced in the error message is only used for backwards compatibility. Since this is a brand new web app, I'm not concerned about backwards compatibility. So I thought I could just remove the offending dll from my website "bin" folder. But then I get the same error message, except now it references one of the new OSGeo.MapGuide dlls. 

 

 Has anyone come across this? Anybody know how to fix it?

Valued Mentor
jackie.ng
Posts: 284
Registered: ‎10-06-2008
Message 2 of 4 (1,805 Views)

Re: Error - Could not load file or assembly MapGuideDotNetAPI

01-02-2012 03:49 PM in reply to: georgega

It's most likely a 32-bit/64-bit problem. One of these things doesn't match:

 

  • You are using 64-bit MapGuide dlls from a 32-bit web application or vice versa
  • Your web application is configured to be 32-bit in IIS, but using 64-bit dlls or vice versa

- Jackie

Active Contributor
soudemans
Posts: 26
Registered: ‎09-10-2009
Message 3 of 4 (1,761 Views)

Re: Error - Could not load file or assembly MapGuideDotNetAPI

01-10-2012 02:22 PM in reply to: jackie.ng

Jackie,

 

Could you elaborate on how to determine which is which


 

  • You are using 64-bit MapGuide dlls from a 32-bit web application or vice versa
  • Your web application is configured to be 32-bit in IIS, but using 64-bit dlls or vice versa

- Jackie


  1. How can you tell what DLLs (64 or 32 bit) you are using?
  2. How do you determine what your application is configured for?
  3. When would you want to configure your application for 64 bit?  Like what should it be if we are running MapGuide OSGeo 64 bit on Windows 2008 R2 Server?
  4. This final question depends a little on your previous answer: Where do we get the drivers once we know what we need?

Thanks,

 

Sierk

Board Manager
Daniel.Du
Posts: 224
Registered: ‎12-23-2008
Message 4 of 4 (1,569 Views)

Re: Error - Could not load file or assembly MapGuideDotNetAPI

07-23-2012 11:54 PM in reply to: soudemans

 

This video may be helpful for you.

 

Video : Autodesk® Infrastructure Map Server 2012 API Webcast
Recorded version of the Autodesk® Infrastructure Map Server 2012 API webcast
View Online | Download

 

 



Daniel Du
Developer Technical Services
Autodesk Developer Network

Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Are You Going To Be @ AU 2014? Feel free to drop by our AU topic post and share your plans, plug a class that you're teaching, or simply check out who else from the community might be in attendance. Ohh and don't forgot to stop by the Autodesk Help | Learn | Collaborate booths in the Exhibit Hall and meet our community team if you get a chance!