Useful program. But I had to knock off two stars due to a serious bug which caused me to lose all the work I'd just done on a snippet. Clicking save produced no errors, caused the "*" to be removed from the editor tab and allowed it to be closed. But the changes were lost. On closer investigation I noticed that it had appended the snippet path to itself. This happened a few times but I haven't figured out how to reproduce it.
So I wanted to see what snippets I could start using in VS 2010, and realized there was no way to browse the built-in snippet collections. What??
Snippet Designer to the rescue. Not only does it allow you to create new snippets on the fly from your code, but it also includes a much-needed Snippet Explorer, to browse what snippets are currently available.
It was like a soothing salve applied directly to my brain. Thanks!
I would like to create a code snippet that automatically inserts the sub or function name. For example, if my shorcut to my snippet is Loge, then I would like it to automatically insert:
Log.Info("Entering MethodType FunctionName(params)")
- where MethodType could be Function or Sub depending on the type
- where FunctionName is the name of the function or subroutine
Is this possible? I see where we can use tags delimited with $tag$, but not sure how to map this to represent what I want.
so far i have tried to create and import about 3 snippets.
after making all three using the right click and export option when i go to import them (after opening them in the editor and adding in some replacement vars) i get the message selected snippets are not valid.
not really a pro at making snippets (why i am really looking forward to this tool =]) so i have tried some simple steps, looking for illegal chars ect.
Note: all are language="sql"
so i made another one with a very simple body,
<Code Language="sql"><![CDATA[select *
still getting the same error message, not sure what i am missing. hope its not a simple step that is in a doc that i missed....
Thanks in advance for any help!
Firstly thanks for developing fantastic extension for Visual Studio.
Found a bug where when we click on 'Export as snippet' in code-behind file it shows 'Add new item' dialog. I guess its only happening in ASP.NET project and I'm using VS 2010.
Installed this on VS 2013 and it works like a champ, will save me many hours of time.
Only bugger i have noticed is the replacement back ground color
The default is to light on the dark theme making them unreadable.
I noticed there is a theme color identified for this however it seems to be ignoring the updates for the theme. so I am not sure where it is drawing that color from.
I'm using Visual Studio 2012 Update 2 version 4.5.50709.
By default, the snippet folder it is watching for My Code Snippets is at:
C:\Users\<USERNAME>\Documents\Visual Studio 11\Code Snippets\SQL_SSDT\My Code Snippets
(It is using SQL_SSDT rather than SQL as part of the folder name)
Also, if you view the XML of the snippet created by Snippet Designer, it is showing Code Language="sql" rather than Code Language="SQL_SSDT". If you manually change a saved snippet to "SQL_SSDT" (and make sure the snippet is in a folder watched by VS) it shows up in the list of SQL snippets.
If you can make these 2 changes then SQL snippets should work in VS 2012. Thanks!
I read VS 2012 Express RC is supported, but now I have tried installing it into actual VS 2012 Express (no RC) and got this:
Microsoft Visual Studio Express 2012 for Windows 8
Microsoft Visual Studio Express 2012 for Windows Desktop
VSIXInstaller.NoApplicableSKUsException: This extension is not installable on any currently installed products.
Am I doing something wrong, or has there been some change in VS from RC to official release?
When I go to add a new file, the Snippet designer template is not shown. This is the only extension I installed other than the NuGet Package manager update. I'on Windows 64 bit, VS 2012, in a website project.
I have installed snipped designer but when i try to export the snipped code changes, (Via Export snipped option),its doesn't open the file in usual .snippet format. Tool asks me to provide a extension for the file to be saved.I have tried even simple thing like console.Readline()( just to avoid any code mistakes) but nothing works. Any idea what might be wrong ?
Some more information might help me.
1. Visual Studio Version
2. What project type where you in (Website, Web Application, Console App,... etc)?
3. What other extensions do you have installed?
4. What language is your VS in (e.g. english)?