What are the challenges you face when working across database platforms? Take the survey
Options

SA forces my NET 2 project to use NET 4 assemblies

danperdanper Posts: 2
edited October 16, 2012 9:44AM in SmartAssembly
I have a a DLL project that is built for .NET 2.0.
The project uses 3rd party DLLs (dependencies) that are built for .NET 4.0.
This is perfectly valid and builds with VS 2010.

But after obfuscating the assembly, somehow SA thinks I need .NET 4.0, and replaces the .NET 2.0 references with 4.0 ones.
So when I run it in my app it crashes saying that my DLL wants System.Windows.Forms v4.0 when I have never linked to this .NET assembly.
Also when I open up the DLL in Reflector, it shows references to System.Windows.Forms v4.0, clearly something that SA has added.
This is a bug/incorrect feature in SA and should be corrected in the next version.

Is there a way to force SA to keep my .NET 2.0 assembly references?

Comments

Sign In or Register to comment.