我必須將C++項目的目標框架從4.0更改爲3.5。我發現這個問題/回答如何做到這一點有所幫助:Change C++/CLI project to another framework than 4.0 with vs2010
我碰到以下問題,但:我得到警告:將C++項目從4.0轉換爲3.5框架
warning MSB3258: The primary reference "path\file.dll" could not be resolved because it has an indirect dependency on the .NET Framework assembly "mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" which has a higher version "4.0.0.0" than the version "2.0.0.0" in the current target framework
與同爲System, Version=4.0.0.0
,Microsoft.VisualC, Version=10.0.0.0
,System.Configuration, Version=4.0.0.0
,System.Xml, Version=4.0.0.0
,System.Security, Version=4.0.0.0
,和System.Data.SqlXml, Version=4.0.0.0
。這會導致依賴於無法找到的file.dll的所有項目出現錯誤。
我不知道如何解決這個問題。我也安裝了Visual Studio 2008 - 儘管它似乎並不在意,並且使用Platform Toolset v90甚至可以使C++項目無法構建。請幫忙 !
您是否安裝了3.5框架? http://www.microsoft.com/download/en/details.aspx?id=21 – 2012-04-24 21:41:08
是的,並且所有的網絡應用程序我都能正常工作,除了那些依賴於我試圖修復的應用程序 – Thalia 2012-04-24 21:50:18