Not sure whether this is an issue or not, but sometimes I get this warning from my build:
The following assembly has dependencies on a version of the .NET Framework that is higher than the target and might not load correctly during runtime causing a failure: AjaxControlToolkit, Version=15.1.4.0, Culture=neutral, PublicKeyToken=28f01b0e84b6d53e. The dependencies are: System.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a. You should either ensure that the dependent assembly is correct for the target framework, or ensure that the target framework you are addressing is that of the dependent assembly.
What makes this odd is that:
1) I don't encounter it all the time. e.g. if I "clean" my build, then do a "rebuild all" I don't normally see it (but sometimes I do).
2) my applications web.config has these lines in it:
<compilation targetFramework="4.5.2">
<httpRuntime targetFramework="4.5.2"/>
Both of which (in my opinion) meet the requirement that "the dependent assembly is correct for the target framework" (i.e. because 4.5.2 is higher than the System.Design Version=4.0.0.0 that it is complaining about).
Anyway's, just wondering if anybody else has encountered this (as I don't really want my release build fooming on my live server).
Thanks
Chris
Comments: I have sorted my build out now: my dependency trace shows that all my assemblies/dlls target asp.net 4.0.0.0 (or above). Thus I regard the issue as now fixed. In general: if you see a message like "The following assembly has dependencies on a version of the .NET Framework that is higher than the target and might not load correctly during runtime causing a failure:", trace your dependencies out (e.g. using Assembly.GetReferencedAssemblies()), and check to see whether your mixing asp.net 4.0.0.0 with asp.net 2.0.0.0 (I was!).
The following assembly has dependencies on a version of the .NET Framework that is higher than the target and might not load correctly during runtime causing a failure: AjaxControlToolkit, Version=15.1.4.0, Culture=neutral, PublicKeyToken=28f01b0e84b6d53e. The dependencies are: System.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a. You should either ensure that the dependent assembly is correct for the target framework, or ensure that the target framework you are addressing is that of the dependent assembly.
What makes this odd is that:
1) I don't encounter it all the time. e.g. if I "clean" my build, then do a "rebuild all" I don't normally see it (but sometimes I do).
2) my applications web.config has these lines in it:
<compilation targetFramework="4.5.2">
<httpRuntime targetFramework="4.5.2"/>
Both of which (in my opinion) meet the requirement that "the dependent assembly is correct for the target framework" (i.e. because 4.5.2 is higher than the System.Design Version=4.0.0.0 that it is complaining about).
Anyway's, just wondering if anybody else has encountered this (as I don't really want my release build fooming on my live server).
Thanks
Chris
Comments: I have sorted my build out now: my dependency trace shows that all my assemblies/dlls target asp.net 4.0.0.0 (or above). Thus I regard the issue as now fixed. In general: if you see a message like "The following assembly has dependencies on a version of the .NET Framework that is higher than the target and might not load correctly during runtime causing a failure:", trace your dependencies out (e.g. using Assembly.GetReferencedAssemblies()), and check to see whether your mixing asp.net 4.0.0.0 with asp.net 2.0.0.0 (I was!).