2017-09-26 74 views
0

我有一個非常簡單的項目,突然想要加載.NET版本2Asp.NET Web應用程序堅持加載.NET 2.0

web.config<compilation>標籤包括targetFramework="4.6.1"

下的目標框架項目屬性也設置爲4.6.1

但IISExpress實例顯示版本2

enter image description here

<?xml version="1.0"?> 
<configuration> 
    <appSettings/> 
    <connectionStrings> 
    <add connectionString="xxx" name="x"/> 
    </connectionStrings> 
    <system.web> 
    <compilation debug="true" targetFramework="4.6.1"/> 
    <authentication mode="Windows"/> 
    <pages controlRenderingCompatibilityVersion="3.5" clientIDMode="AutoID"/> 
    </system.web> 
</configuration> 

回答

0

我通過更新解決方案文件中的目標框架解決了這個問題

相關問題