16

I imported a snippet, and I want it gone. Problem is that the Snippet Manager has the Remove button grayed out when I go in and try to remove it, any ideas?

naspinski
  • 34,020
  • 36
  • 111
  • 167

3 Answers3

13

Chances are that code snippet was imported to Program Files folder (e.g. C:\Program Files (x86)\Microsoft Visual Studio 11.0\Web\Snippets\CSS\1033\CSS) instead of C:\Users\\Documents\Visual Studio 2012\Code Snippets

Snippet Manager displays the location of selected snippet, just go there, delete it manually and restart Visual Studio.

Jarek Kardas
  • 8,445
  • 1
  • 31
  • 32
  • Why do they still have a remove button?! My snippets located in my user location C:\Users\\Documents\Visual Studio 2013\Code Snippets\Visual C#\My Code Snippets – Andez Nov 04 '16 at 09:48
3

Yes, this is because you can only remove directories and not individual snippets (at least from the Code Snippets Manager, you know, Microsoft style!):

To remove a directory from the Code Snippet Manager, select the directory that you want to remove.

Reference: https://msdn.microsoft.com/en-us/library/9ybhaktf(v=vs.100).aspx

Exel Gamboa
  • 936
  • 1
  • 14
  • 25
0

For Ubuntu users, please remove snippet files in ~/.config/Code/User/snippets
Not sure if applicable for other Linux distributions.

zstbsqx
  • 60
  • 8