Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

visual studio cannot open new project

Whenever I try to create a new project in VS 2010 I get the error:

New project/item dialog could not be initialized due to error: Exception of type 'Microsoft.VisualStudio.Dialogs.DialogInitializationException' was thrown.

And when try to open existing project visual studio 2010 restarts.

like image 238
jonny Avatar asked Jun 09 '12 17:06

jonny


People also ask

How do I open a new Project in Visual Studio?

If the Visual Studio development environment is already open, you can create a new project by choosing File > New > Project on the menu bar.

How do I open a new C# Project in Visual Studio?

Open Visual Studio, and choose Create a new project in the Start window. In the Create a new project window, select All languages, and then choose C# from the dropdown list.

How do I open a Project in Visual Studio 2022?

Open Visual Studio. On the start window, select Open a project or solution. Visual Studio opens an instance of File Explorer, where you can browse to your solution or project, and then select it to open it.


2 Answers

I had the same problem on my computer. After a long time searching I solved it by the following steps:

  1. Close all instances of Visual Studio
  2. Go to "C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE" (or whatever is your VS installation directory)
  3. Run command devenv.exe /resetuserdata and wait until finished
  4. Run Visual Studio
like image 184
Lukash Avatar answered Oct 16 '22 03:10

Lukash


Close all VS instances and try the solution mentioned here:

  • Launch Developer Command Prompt for VS 2017 as Administrator
  • Go to VS 2017 installation folder, for example: pushd C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise
  • gacutil -if Common7\IDE\PublicAssemblies\Microsoft.VisualStudio.Shell.Interop.8.0.dll
like image 29
Neerkoli Avatar answered Oct 16 '22 01:10

Neerkoli