Visual Studio 2010: Could not resolve mscorlib for target framework '.NETFramework,Version=v4.0'

前端 未结 21 2911
谎友^
谎友^ 2020-12-14 14:31

We are currently migrating all our solutions from 2005 to 2010 (that\'s right, we\'re skipping 2008!). We are also changing our file structure to make some more sense (some

21条回答
  •  挽巷
    挽巷 (楼主)
    2020-12-14 14:50

    I had this problem today and the solution was to manually edit the Resources.resx file manually.

    My Resources.resx file looked like this:

      
        I am a string
      
      
      
        ..\Resources\MyLogo.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
      
      
        ..\Resources\Open.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
      
    

    Turned out that Visual Studio didn't like the two elements after the element, which is strange considering the fact that Visual Studio added them there itself. My problem was solved after I moved them before the element:

      
        I am a string
      
      
        ..\Resources\MyLogo.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
      
      
        ..\Resources\Open.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
      
      
    

提交回复
热议问题