问题
I am upgrading some old services. Some dlls it's using are referencing Sybase.AdoNet2.AseClient but new dlls that I am adding reference Sybase.AdoNet4.AseClient. I keep getting errors saying "Major version mismatch sybdrvado20.dll. Expecting major version '2'. Loaded version 1" and vis-versa.
Does anyone know how I can resolve this issue? Is it just not possible for a project to reference dlls that expect different versions of a dll?
Thanks,
回答1:
Reference both assemblies and change the Alias property of one. You can find more information here:
- http://www.lloydkinsella.net/blog/2012/07/13/extern-alias-underused-or-unknown/
来源:https://stackoverflow.com/questions/26553045/can-a-project-use-2-different-versions-of-the-same-dll-sybase-adonet-2-and-4