Visual Studio 2010 Project Template doesn't show up

寵の児 提交于 2019-12-12 09:45:38

问题


I tried to edit a project template after exporting it from vs2010 by extracting it and after editing compressing it again. But after that it won't show up in visual studios new project dialog.

So I tried it again, without the editing. Just extract and compress again. I even used windows zip mechanisms, but still wont work. Only the exported template works fine.

I also tried what's written here: http://msdn.microsoft.com/en-us/library/ms185298.aspx to no avail.

So is there some magic incantation nobody told me about to get it to work?


回答1:


Be carefull following Step 7 in http://msdn.microsoft.com/en-us/library/ms185298.aspx.

DON'T send the whole Folder to a zip file... only the files inside!




回答2:


Actually, there's a documented way to get VS to populate the template cache folder by just deploying the zipped template to the ProjectTemplates\etc. folder:

<Path to devenv.exe> /installvstemplates

Works on every version of VS since 2005 (and possibly even earlier versions).




回答3:


There are actually two places where templates are kept. *Templates and *TemplatesCache (where * is Item or Project). You need to update the template in both places. Note, the cache has the templates extracted from the zip file in a subdirectory that has the same name as the zip.



来源:https://stackoverflow.com/questions/3941943/visual-studio-2010-project-template-doesnt-show-up

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