3

Closed

New | File does not list the Code Snippet File template

description

When we are trying to create a new snnipet, using the right click and choosing "Export as Snippet", the Code Snippet File template does not appear.

file attachments

Closed Jan 18, 2012 at 5:04 PM by mmanela
Closing fixed issues

comments

chila wrote Nov 24, 2008 at 2:23 PM

I can see that there is something missing between my two environments. At work, the snippet designer was launched when I decided to export a portion of code as a Snippet. It might be something missing at my home PC. See you.

flow7oo wrote Dec 31, 2008 at 8:52 AM

I have the same issue. Any solutions yet?

mmanela wrote Jan 15, 2009 at 11:20 PM

The dialog that screen shot shows is not where the snippet template should show up.
It shows up under File->New->File...
The image you uploaded shows a different dialog, I uploaded an image of what the correct dialog looks like for me called:WORKING_File_New_File.png.


Could you answer some more questions to help me figure what is wrong.
  1. Do you see Code Snippet File in File->New->File... dialog?
  2. What is your visual studio install path?
  3. Do you see a SnippetDesigner.vsdir file and a SnippetFile.snippet file at this path:
    [Path to your vs install]\Common7\IDE\NewFileItems ?

world4geeks wrote Feb 11, 2009 at 6:24 AM

Actua;;y i was also facing the same problem.In some projects it is working and in some other it is not working.my project type was website where it is not working.Then i search and found this article helpful.

http://phanibitra.co.cc/index.php/Visual-Studio/Snippet-Designer-a-visual-Studio-Addin-Bug-Fixed.html

I followed the instructions given in that article and it solved my problem

sespark wrote Feb 15, 2010 at 5:53 PM

In a web site project, not a web application, the 'Export as Snippet' from the right click context menu brings up the New Item Dialog box instead of the Snippet Designer. I have seen this in multiple site projects, while it works for me in web applications. This is for Visual Studio 2008.

Details:
Visual Studio 2008 SP1
Project: Web Site
File: ASPX Code Behind and App_Code
Install Path: C:\Program Files\Microsoft Visual Studio 9.0\
Snippet Item not present in New Item Dialog
SnippetDesigner.vsdir and SnippetFile.snippet file are present in the "C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\NewFileItems" folder.

sespark wrote Feb 15, 2010 at 6:00 PM

And the provided fix does not seem to work for me.

Language: VB.NET
Environment Settings: General

mmanela wrote May 27, 2010 at 7:27 AM

Fixed for VS 2008 in rev 236fad4f9427
Fixed for VS 2010 in rev ab9936b7006a