error was an error running the selected code generator:invalid pointer(Exception from HRESULT:0x80004003(E_POINTER))

4

i'm working with asp.net mvc with visual studio community 2015. i need to create new View with name "aaaaaa" but when i try to create new controller and add new view, i have an error

error was an error running the selected code generator:invalid pointer(Exception from HRESULT:0x80004003(E_POINTER))

enter image description here

can some one tell me what happen? and how i can fix this issue?

asp.net
asp.net-mvc
visual-studio
visual-studio-2012

2 Answers

2

For me this error began to appear after installing Web Essentials (a Visual Studio extension). I tried to repair the installation, but the error remained even after that. So I tried the following command (no need for administrative privileges) after closing all instances of Visual Studio that were currently running:

devenv.exe /resetuserdata

Here's the link to the Web Essentials version that broke my Visual Studio. At the time of this writing the current version was 1.0.198.

answered on Stack Overflow Dec 25, 2015 by Zignd • edited Dec 25, 2015 by Zignd
2

I also had this error. Plus I was also getting the error "object reference not set to an instance" when trying to open existing views.

I found the answer here: https://stackoverflow.com/a/35815094/5935995

I had to clear the ComponentModelCache by:

  1. Close Visual Studio
  2. Delete everything in this folder C:\Users\AppData\Local\Microsoft\VisualStudio\14.0\ComponentModelCache
  3. Restart Visual Studio
answered on Stack Overflow Apr 10, 2016 by kwilliams • edited May 23, 2017 by Community

User contributions licensed under CC BY-SA 3.0