WPF - Some Assembly references are Missing Visual Studio 2022

When I create a WPF form in Visual Studio 2022, I get the error, Some assembly references are missing. Building to restore the NuGet cache might resolve this issue.

I’ve uninstalled VS2022 and reinstalled it to try and resolve the issue, but no luck.

Tool: Visual Studio, Visual Studio Code, PSScriptPad, PowerShell Module
Version: Powershell Tools 2021.12.2

This is a known issue with Visual Studio 2022. We are investigating how to resolve it.

Thanks for the as always quick reply.

I’m still experiencing this issue. Was there ever a fix for this?

VS2022_WPF_AssemblyRefIssue

Visual Studio Community 2022 (64-bit) v17.6.2
PowerShell Pro Tools for Visual Studio 2023.2.1

I’m also having this problem.

Visual Studio 2022 Pro (64-bit) v17.6.3
PowerShell Pro Tools for Visual Studio 2023.2.1

Can you let me know if you have the .NET Framework 3.5 feature installed?

image

We noticed a problem with PSScriptPad and WPF references and enabling this seemed to work around it.

Yes, I have .NET 3.5 installed. There was also an issue with PSScriptPad drawing incorrectly when launching from VS Code, but launching standalone seems to work okay.

I enabled the .NET Framework 3.5, but it did not help. Cleaning and rebuilding the project/solution doesn’t either. WPF form runs fine when running/debugging the .ps1 from VS. I just can’t get the designer in VS to work.

image

Updated to the newest 2023.6.0 PoSH tools extension on Visual Studio Pro 2022 v17.6.4. Same behavior as before.

Also cannot open the .xaml file in Blend 2022 17.6.4

I just built a new machine and can reproduce this. I will circle back when I figure out a fix\work around.

EDIT: I was also able to reproduce this by updating to the latest version of VS2022.

Great news. I’m glad I’m not alone here.

Any Update on this? I am now to Powertools, and WPF GUI is why I bought it. If I could still download Visual Studio 2019 it would not be an issue. Any one know where I can download 2019???

Have you tried searching the web for “Visual Studio 2019 download” ?

I don’t remember seeing this limitation when I purchased it. I guess that’s the official solution.

image

image