[mapguide-users] Darn DLL files again

Hans Milling hm at geograf.dk
Fri Feb 10 08:56:58 EST 2012


Hi All

I just installed MGOS2.2 on a 2003 server an copied my web application to
it. When I start my application (using the MaestroAPI 4, local native
connection with the signed 2.2 dll files). I get an error message:

System.IO.FileNotFoundException: Could not load file or assembly
'MapGuideDotNetApi, Version=2.0.0.2308, Culture=neutral,
PublicKeyToken=f526c48929fda856' or one of its dependencies. The system
cannot find the file specified. File name: 'MapGuideDotNetApi,
Version=2.0.0.2308, Culture=neutral, PublicKeyToken=f526c48929fda856' at 

I did not reference the MapGuideDotnetAPI.dll file, but the other individual
files. I thought that it was not needed any more?

Anyway I copy the signed dll (Original from MGOS2.2 mapviewernet\bin folder)
to the bin folder of the web application.
I then get:

System.Reflection.TargetInvocationException: Exception has been thrown by
the target of an invocation. ---> System.IO.FileLoadException: Could not
load file or assembly 'MapGuideDotNetApi, Version=2.0.0.2308,
Culture=neutral, PublicKeyToken=f526c48929fda856' or one of its
dependencies. The located assembly's manifest definition does not match the
assembly reference. (Exception from HRESULT: 0x80131040) File name:
'MapGuideDotNetApi, Version=2.0.0.2308, Culture=neutral,
PublicKeyToken=f526c48929fda856' at
OSGeo.MapGuide.MaestroAPI.Native.LocalNativeConnection.InitConnection(String
sessionid) at...

My application is referencing the 1.0.0.1 version of the DLL files (except
the MapGuideDotnetApi.dll that is not referenced at all). Also the
2.0.0.2308 version referenced by the MaestroAPI is from MGOS2.0 i believe?).
Ok, so next I add this to my webconfig, to make sure that any version of the
DLL is treated as my 1.0.0.1 version:

  <runtime>
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
      <dependentAssembly>
        <assemblyIdentity name="MapGuideDotNetApi"
publicKeyToken="f526c48929fda856" />
				<bindingRedirect oldVersion="1.0.0.0-10.10.10.10" newVersion="1.0.0.1"
/>
      </dependentAssembly>
    </assemblyBinding>
  </runtime>

I then get the following error:
System.Reflection.TargetInvocationException: Exception has been thrown by
the target of an invocation. ---> OSGeo.MapGuide.MgConfigurationException:
Failed to retrieve message for "MgConfigurationException". -
MgSiteConnection.Open line 103 file
c:\builds\mg22win32\mgdev\common\mapguidecommon\Services/SiteConnection.cpp

Looks like some reference/DLL mismatch
This is where I am stuck? What am I doing wrong?

Best regards
  Hans Milling...

--
View this message in context: http://osgeo-org.1560.n6.nabble.com/Darn-DLL-files-again-tp4383375p4383375.html
Sent from the MapGuide Users mailing list archive at Nabble.com.


More information about the mapguide-users mailing list