8/30/2009

SharePoint: Code Snippets in SharePoint Designer!

Visual Studio has a large number of “canned” blocks of code that can be quickly added to a project using a shortcut key. These are call Snippets. Turns out that SharePoint Designer has them too. But only a few…

Inserting a Snippet:

Click in the code window where you want the Snippet and press Ctrl-Enter (or click Edit, IntelliSense, List Code Snippets):

    image

 

Creating your own Snippets:

You can create your own Snippets either by using a shortcut or by going to Tools and Page Editor Options.

Shortcut:

  1. Select existing text you would like to use for a Snippet
  2. Right-click and select Create Code Snippet

Or go to Tools, Page Editor Options:

    image

 

.

No comments:

Note to spammers!

Spammers, don't waste your time... all posts are moderated. If your comment includes unrelated links, is advertising, or just pure spam, it will never be seen.