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

前端 未结 21 2933
谎友^
谎友^ 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条回答
  •  萌比男神i
    2020-12-14 15:01

    I ran in to this problem today, and it proved to be caused of too long filenames in the project.

    This, in turn, was caused by some service references. When a service reference is imported or updated, visual studio generates .datasource files, where the filename is the fully qualified name. This means really long names in some instances.

    By googling around, I found hints that it was safe to delete these files. Check this or this out.

    Deleting these .datasource files removed the problem.

提交回复
热议问题