<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:creativeCommons="http://backend.userland.com/creativeCommonsRssModule"
>

<channel>
	<title>Martin Normark&#039;s blog &#187; Visual Studio</title>
	<atom:link href="http://martinnormark.com/tag/visual-studio/feed" rel="self" type="application/rss+xml" />
	<link>http://martinnormark.com</link>
	<description></description>
	<lastBuildDate>Tue, 15 May 2012 21:06:09 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
<creativeCommons:license>http://creativecommons.org/licenses/by/3.0/</creativeCommons:license>
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>Optimizing Code Snippets</title>
		<link>http://martinnormark.com/optimizing-code-snippets?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=rss</link>
		<comments>http://martinnormark.com/optimizing-code-snippets#comments</comments>
		<pubDate>Wed, 12 Dec 2007 23:06:00 +0000</pubDate>
		<dc:creator>Martin Normark</dc:creator>
				<category><![CDATA[Visual Studio]]></category>

		<guid isPermaLink="false">/post/Optimizing-Code-Snippets.aspx</guid>
		<description><![CDATA[Code Snippets are a great productivity boost that was introduced in Visual Studio 2005, if I remember right. Code Snippets lets you type a shortcut for a piece of code. I use snippets for properties a lot. I hate writing &#8230; <p><a class="btn small" href="http://martinnormark.com/optimizing-code-snippets">Continue reading <span class="meta-nav">&#8594;</span></a></p>]]></description>
			<content:encoded><![CDATA[<p>Code Snippets are a great productivity boost that was introduced in <a href="http://search.live.com/results.aspx?q=Visual+Studio+2005&amp;FORM=WLSTIK&amp;src=IE-SearchBox">Visual Studio 2005</a>, if I remember right. <a href="http://aspalliance.com/752">Code Snippets</a> lets you type a shortcut for a piece of code. I use snippets for properties a lot. I hate writing properties "by hand" - it is much faster with Code Snippets. But since <a href="http://www.visualstudio2008.defyallchallenges.com/">Visual Studio 2008</a>, the default prop shortcut now uses Dynamic Properties - but I still work on some projects that does not support Dynamic Properties. So I changed my default Code Snippets, and added a few other.</p>
<p>First I changed the default prop snippet back to the old property with a backing field. Then I added snippets for a Dynamic Property, Business Object Property (to use with Rockford Lhotka's <a href="http://forums.lhotka.net/">CSLA architecture</a>) and a ViewState Property. See the code they all produce here:</p>
<p><a href="/image.axd?picture=WindowsLiveWriter/OptimizingCodeSnippets_1AA/image_4.png"><img style="border: 0px;" src="/image.axd?picture=WindowsLiveWriter/OptimizingCodeSnippets_1AA/image_thumb_1.png" border="0" alt="image" width="354" height="573" align="left" /></a> This boosts productivity even more, and it is a great way to get rid of those lame things you do over and over again...</p>
<p>Download the snippets yourself bellow. Add them to your <strong>C:\Program Files\Microsoft Visual Studio 9.0\VC#\Snippets\1033\Visual C#</strong> directory, and replace the prop.snippet file when it prompts you.</p>
<div id="scid:0767317B-992E-4b12-91E0-4F059A8CECA8:c54041dc-fcd4-4f7f-9a1b-578c2cc02df8" class="wlWriterSmartContent" style="display: inline; margin: 0px; padding: 0px;">Technorati Tags: <a rel="tag" href="http://technorati.com/tags/Visual%20Studio%202008">Visual Studio 2008</a></div>
<p><a rel="enclosure" href="/file.axd?file=CodeSnippets.zip">CodeSnippets.zip (2.29 kb)</a></p>
]]></content:encoded>
			<wfw:commentRss>http://martinnormark.com/optimizing-code-snippets/feed</wfw:commentRss>
		<slash:comments>7</slash:comments>
	<creativeCommons:license>http://creativecommons.org/licenses/by/3.0/</creativeCommons:license>
	</item>
	</channel>
</rss>

