No templates available when creating a new project in Visual Studio

*爱你&永不变心* 提交于 2020-07-17 10:33:16

问题


"No template information found. See the application log in Event Viewer for more details. To open Event Viewer, click Start, click Control Panel, double-click Administrative Tools, and then double-click Event Viewer."

That's the error message I get when I try to create a new project or solution. How can this be resolved?


回答1:


I used a solution presented to me from other sites. One of them said to reinstall templates. I did the following:

In the command prompt I typed: cd C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE

Then I typed: devenv /installvstemplates

I took a minute but after it completed I opened Visual Studio and tried to create a new project. All my project templates were back in order, including additional templates like Workflow, SharePoint and Silverlight.

Link to other source




回答2:


Start Menu --> Microsoft Visual Studio 2008 --> Visual Studio Tools. Right-click over the Visual Studio Command Prompt shortcut and make sure you select Run as Administrator. Once the VS Command Prompt comes up, execute the command without Quot,

  1. "devenv /installvstemplates"

  2. "devenv /resetsettings"

    And that worked out.




回答3:


Run Following command and it will restore templates. C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE>devenv /installvstemplates




回答4:


This may not match the original posters exact symptoms but I was seeing a blank screen after clicking Create a new project (VS 2019). Discovered that the install of Visual Studio had 'finished with errors' (paraphrasing there - now I've fixed the issue I can't see the exact error message) anyhow digging into it I found that the C++ redistributable had not installed (even though I'm a C# dev that's still important to VS!)

If I tried to install this as a standalone I got an Access Denied error (even if running as Administrator). Digging into the VS install logs I found a similar report.

Anyhow after a fair amount of Googling a few responses pointed to Virus software preventing the C++ redistributable from installing (in my case McAfee). Once that was removed a repair of VS resolved the issue :)



来源:https://stackoverflow.com/questions/1643357/no-templates-available-when-creating-a-new-project-in-visual-studio

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!