4

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?

Sven Hecht
  • 1,337
  • 1
  • 16
  • 23

3 Answers3

16

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!

Community
  • 1
  • 1
pyranha
  • 184
  • 1
  • 4
  • +1!!! Thanks so much for this! I spent so much time troubleshooting and the whole reason I kept failing was because I wasn't doing what you said in your last statement. – Frank Hale May 11 '12 at 17:20
3

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).

Andy Hopper
  • 3,618
  • 1
  • 20
  • 26
0

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.

  • where can I find this cache for VS2010? c:\Users\\AppData\Roaming\Microsoft\VisualStudio\10.0\ does not contain any templatesCache folder like the others. – Sven Hecht Oct 15 '10 at 13:58
  • @Sven its under ProgramFiles. For me, C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\ItemTemplatesCache\ –  Oct 15 '10 at 15:46