When you insert a code snippet, the editor highlights the fields (variables, values, etc) you can modify depending on how the code snippet was written.   The idea is you modify the contents of the field, then press tab to navigate to the next field.  When you press tab, that particular field is updated throughout the entire snippet.  You can also navigate outside the field via the arrow keys to invoke the update. 

For Loop C# Snippet

If you press enter, however, you will be committing both the current change (if any) and the entire snippet, meaning you can’t undo to get back to those highlighted fields.  You would have to use your favorite refactoring method to make any additional updates.  I call this out because I always press enter when i meant to hit tab.  No idea why this got hard-coded into my head, so just a heads-up.

For those of you who found this tip outside the tip of the day series, you can read more about code snippets on the VS Editor Team Blog.

Technorati tags: VS2005Tip, VS2008Tip