Notice: This website is an unofficial Microsoft Knowledge Base (hereinafter KB) archive and is intended to provide a reliable access to deleted content from Microsoft KB. All KB articles are owned by Microsoft Corporation. Read full disclaimer for more details.

Error message when you compile applications to target the .NET Framework 4.5.2


Symptoms

When you recompile a Microsoft .NET Framework 4.5.1 application that uses .NET portable libraries to target the Microsoft .NET Framework 4.5.2, you receive the following error message during compilation:
The type '{type}' is defined in an assembly that is not referenced. You must add a reference to assembly '{assembly}'.

Note In this error message, {assembly} represents one of the actual files that is found in the "C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\Facades" folder.

For example, the error message resembles one of the following messages:
The type 'System.Object' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.
The type 'System.Attribute' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.

↑ Back to the top


Resolution

To resolve this problem, install the updated version of the Microsoft .NET Framework 4.5.2 Developer Pack. For download information, see Microsoft Knowledge Base article 2901951 .

↑ Back to the top


Keywords: kbtshoot, kbexpertiseinter, kbsurveynew, kb

↑ Back to the top

Article Info
Article ID : 2971005
Revision : 1
Created on : 1/7/2017
Published on : 6/19/2014
Exists online : False
Views : 140