Skip to content

Latest commit

 

History

History
33 lines (24 loc) · 1.4 KB

ca0058.md

File metadata and controls

33 lines (24 loc) · 1.4 KB
description title ms.date ms.topic f1_keywords helpviewer_keywords author ms.author manager ms.subservice monikerRange
Unable to load assemblies referenced.
CA0058
10/20/2016
reference
CA0058
CA0058
mikejo5000
mikejo
mijacobs
code-analysis
vs-2019

CA0058

Unable to load assemblies referenced.

This error occurs if the analysis tool is unable to load assemblies referenced by the assembly under analysis. As result, this error might cause CA0001 in other places because many unexpected states can arise if this occurs. If you are using the managed code analysis tool from within Visual Studio, the following are some of the reasons that might cause CA0058:

  • The input assembly was overridden and now points to an assembly that references other assemblies outside the list of references in the Visual Studio project file.

  • If a project is modified to invoke a custom build step before FxCopCmd.exe runs and the custom build process adds more references to the input assembly, error CA0058 is generated.

  • In C++, it is possible to reference assemblies using ForcedUsing in VCPROJ, overriding the command-line to pass / ForcedUsing or adding #using <Some.dll> in source only.

In all cases, the resolution for this issue is to add the missing reference to the Visual Studio project itself.

See also