.net 4.5 framework install issue with VS2010 / web.config / app pools - by The_Akrion

Status : 

  Won't Fix<br /><br />
		Due to several factors the product team decided to focus its efforts on other items.<br /><br />
		A more detailed explanation for the resolution of this particular item may have been provided in the comments section.


2
0
Sign in
to vote
ID 766590 Comments
Status Closed Workarounds
Type Bug Repros 0
Opened 10/8/2012 8:24:58 AM
Access Restriction Public

Description

Here is the install which works and compiles great prior to .net 4.5 framework install.

.net 4.0 framework installed, ASP.NET web site which is targeting .net 3.5 in the build preferences and has all the "start up" and "legacy" entries in the web.config as well as in IIS runs in the .net 2.0 classic app pool. When build is initialed it builds fine since it is not compiled against .net 4.0 compiler which we all know is much stricter. Again it compiles with no issues.

Enter .net 4.5 framework install (with no changes what so ever done to the project) is fails to compile since it tries to compile against .net 4.0 and up. All the web.config entries are there the app pool is again set to .net 2.0 classic and it still compiles for .net 4.0. I know because the errors I get are identical of those I was getting when I set the app pool to work on .net 4.0 prior the .net 4.5 install.

So how can I force the VS2010 and the compiler to target .net 3.5 and not .net 4.0 when I have all the web.config suggested by MS entries as well as the app pool is set to 2.0?

Thanks in advance.

PS. What I mean by web.config legacy & startup:

 <startup useLegacyV2RuntimeActivationPolicy="true">
    <supportedRuntime version="v3.5.30729.1"/>
  </startup>

Changing this section to v2.0 or any other version/combination and even removing the whole startup section makes no difference.


I also have the default 3.5 section:

<compilers>
    <compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CSharp.CSharpCodeProvider, System, Version=3.5.30729.1, Culture=neutral, PublicKeyToken=b77a5c561934e089" warningLevel="4">
      <providerOption name="CompilerVersion" value="v3.5"/>
      <providerOption name="OptionInfer" value="true"/>
      <providerOption name="WarnAsError" value="false"/>
  </compiler>

10/9/2012 Update:

After uninstalling .net 4.5 and then installing .net 4.0 without any changes to the web.config ... the project compiles just fine and I we get no errors what so ever. This exercise was done more than once and it is clear to us that there is something with the .net 4.5 install which changes how the VS2010 compiles. 

10/10/2012 Update: Any framework combination with the web.config section bellow makes no difference.

<startup>
<supportedRuntime version="v2.0.50727"/>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5"/>
</startup>
Sign in to post a comment.
Posted by Varun [MSFT] on 4/19/2013 at 9:12 AM
If your .NET4 app is impacted by this issue, please contact netfx45compat at microsoft dot com. We would like to understand this better.

Thanks
Varun Gupta
.NET Framework Compatibility
Posted by Damian [MSFT] on 3/1/2013 at 11:43 AM
Unfortunately a change in the behavior would be a breaking change and as such we can't make a fix in any future in-place update. Please use the workarouds described in the previous comments.
Posted by Miguel [MSFT] on 1/22/2013 at 11:57 AM
Hi!

Thank you again for reporting this issue. We have determined that it is a bug in the Visual Studio Web Designer API and will consider a fix for the next release of the product.

In the meantime, you can apply an easy workaround which is to set the custom control's property value in code behind and remove the affected property from the mark up.

Hope this helps,

regards,
Miguel A. Lacouture
[MSFT]
Posted by Microsoft on 10/26/2012 at 2:27 PM
We are actively investigating this issue.
Posted by Microsoft on 10/8/2012 at 10:38 PM
Thanks for your feedback. Your issue has been routed to the appropriate VS development team for investigation. We will contact you if we require any additional information.
Posted by Microsoft on 10/8/2012 at 8:50 AM
Thank you for your feedback, we are currently reviewing the issue you have submitted. If this issue is urgent, please contact support directly(http://support.microsoft.com)