Manage code snippets in Notepad++

There is a good plugin to manage code snippets: SnippetPlus .NET 3.5 Required! Code snippet and Surround With plugin for Notepad++. Write snippet name and replace it with real code or select some text and surround it with something like IF,TryCatch,Table,Div or whatever.Will give you hint if you don’t remember the snippet name Note that … Read more

How to create a ‘surround with’ type of snippet in Visual Studio 2010?

It turns out that there are some pre-defined ID’s that are not well documented. Specifically For SurroundWith type snippets, there is an ID $selected$. So, for example, the code for the #if snippet is: … <Code Language=”csharp”> <![CDATA[#if $expression$ $selected$ $end$ #endif]]> </Code> … The $end$ ID indicates where to place the cursor when the … Read more

Any way to surround code block with Curly Braces {} in VS2008?

Here is a quick and dirty snippet to do just that. To Install: Save the code as SurroundWithBraces.snippet into “<my documents>\Visual Studio Version\Code Snippets\Visual C#\My Code Snippets” To use: Select block of text. Press Ctrl+K, Ctrl+S Chose My Code Snippets, braces <?xml version=”1.0″ encoding=”utf-8″ ?> <CodeSnippets xmlns=”http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet”> <CodeSnippet Format=”1.0.0″> <Header> <Title>braces</Title> <Shortcut>braces</Shortcut> <Description>Code snippet to … Read more

How to edit existing VS Code Snippets

The extensions snippets can be found inside each snippet directory below: (if there are snippets in the extension) Mac/Linux: $HOME/.vscode/extensions/ Windows: %USERPROFILE%\.vscode\extensions/ Select the extension you want to modify and then dive into the javascript.json file in snippets/ directory in there, and change whatever you like. Just remember that if/when you choose to download and … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)