I have a project which needs to reference two DLLs with the same name. The DLLs are not strong named, have the same exact name.
I need to access some types within ea
Using extern alias
to bring the assemblies in with different namespaces. If you can differenciate the namespace, you should be able to use using altType1 = someProduct.Type1
to create a local alias for the type.
First qualify the assemblies from the command line:
/r:ProductA=companyDLLA.dll
/r:ProductB=companyDLLB.dll
Then reference them using extern alias
:
extern alias productA;
extern alias productB;
Finally you can alias the local types:
using productTypeA = productA.Type1;
using productTypeB = productB.Type1;