title: What causes error MC1000: Unknown build error, 'Could not find assembly 'System.Runtime.InteropServices.PInvoke...'
body: <p>The full error information is </p>
  
  <p><strong>Code</strong>: MC1000</p>
  
  <p><strong>Description</strong>: Unknown build error, 'Could not find assembly 'System.Runtime.InteropServices.PInvoke, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. Either explicitly load this assembly using a method such as LoadFromAssemblyPath() or use a MetadataAssemblyResolver that returns a valid assembly.'    </p>
  
  <p><strong>File</strong>: C:\Program Files\dotnet\sdk\3.0.100\Sdks\Microsoft.NET.Sdk.WindowsDesktop\targets\Microsoft.WinFX.targets 243 </p>
  
  <p>I'll provide a little context in case it's helpful. This is in a .NET Core 3.0 WPF project, that references a .NET Core 3.0 Console App, that references a .NET Standard 2.0 Class Library. All levels except the top level WPF project also reference a slew of Nuget packages, most of which are probably targeting .NET Standard 1.3 or 2.0. They are all targeting a compatible .NET Standard, I don't have any that are throwing the <a href="https://docs.microsoft.com/en-us/nuget/reference/errors-and-warnings/nu1701" rel="nofollow noreferrer">NU1701 warning</a>.</p>
  
  <p>So the question: what is causing this error?</p>