Reputation: 961
Even after repairing, then uninstalling & reinstalling, when I create a new project with Visual Studio 2022 (which I just downloaded yesterday -- have been using Visual Studio 2017 until then), then go to Project
> {project name} Properties
> Compile
, I get the error
An error occurred trying to load the page. Object reference not set to an instance of an object.
This occurs with every project I've created -- all of which are created using the button on the opening screen "Create a new project" > Windows Forms App (.NET Framework).
Things that have been tried without effect:
Other info that may or may not be relevant:
Screenshot:
The info copied from the "About Microsoft Visual Studio" info from the Help menu is:
Microsoft Visual Studio Community 2022 Version 17.4.4 VisualStudio.17.Release/17.4.4+33213.308 Microsoft .NET Framework Version 4.8.03761
Installed Version: Community
ASP.NET and Web Tools 17.4.326.54890 ASP.NET and Web Tools
Azure App Service Tools v3.0.0 17.4.326.54890 Azure App Service Tools v3.0.0
C# Tools 4.4.0-6.22608.27+af1e46ad38d900023f8b1a2839484e471ece1502 C# components used in the IDE. Depending on your project type and settings, a different version of the compiler may be used.
Microsoft JVM Debugger 1.0 Provides support for connecting the Visual Studio debugger to JDWP compatible Java Virtual Machines
NuGet Package Manager 6.4.0 NuGet Package Manager in Visual Studio. For more information about NuGet, visit https://docs.nuget.org/
TypeScript Tools 17.0.10921.2001 TypeScript Tools for Microsoft Visual Studio
Visual Basic Tools
4.4.0-6.22608.27+af1e46ad38d900023f8b1a2839484e471ece1502 Visual Basic components used in the IDE. Depending on your project type and settings, a different version of the compiler may be used.Visual F# Tools
17.4.0-beta.22512.4+525d5109e389341bb90b144c24e2ad1ceec91e7b Microsoft Visual F# ToolsVisual Studio IntelliCode 2.2 AI-assisted development for Visual Studio.
I've searched on Stack Overflow and elsewhere for things to try, and nothing seems to fix the issue. The closest anything came was a Microsoft help forum where an MS employee gave somebody with a similar situation the advice "your Visual Studio installation may be corrupt, so you may have to repair or even uninstall/reinstall it" (sorry, lost the link). And I tried each of those, but the issue persists.
What can be done to remove this error message and access the Compile settings from a project's Properties?
Upvotes: 2
Views: 1544
Reputation: 11
I had the same problem, but it was fixed by doing Windows Update including .NET Framework update.
Upvotes: 1
Reputation: 483
Based on the solution in the link below, you can try deleting the project's .vs and bin/obj folders and reloading the project.
https://developercommunity.visualstudio.com/t/project-properties-cannot-open-compile-tab/1690795
Upvotes: 0