Click here to Skip to main content
15,902,032 members
Home / Discussions / C#
   

C#

 
QuestionTimers & editing controls Pin
Krylosac15-Nov-11 16:35
Krylosac15-Nov-11 16:35 
AnswerRe: Timers & editing controls Pin
Wayne Gaylard15-Nov-11 17:06
professionalWayne Gaylard15-Nov-11 17:06 
GeneralRe: Timers & editing controls Pin
Krylosac15-Nov-11 17:39
Krylosac15-Nov-11 17:39 
GeneralRe: Timers & editing controls Pin
Wayne Gaylard15-Nov-11 17:53
professionalWayne Gaylard15-Nov-11 17:53 
AnswerRe: Timers & editing controls Pin
Luc Pattyn15-Nov-11 17:28
sitebuilderLuc Pattyn15-Nov-11 17:28 
GeneralRe: Timers & editing controls Pin
BobJanova16-Nov-11 3:11
BobJanova16-Nov-11 3:11 
GeneralRe: Timers & editing controls Pin
Krylosac16-Nov-11 3:24
Krylosac16-Nov-11 3:24 
AnswerRe: Timers & editing controls Pin
Not Active15-Nov-11 17:28
mentorNot Active15-Nov-11 17:28 
QuestionHow To Create Classic Menu in C# desktop apll. Pin
Devdattahack1015-Nov-11 12:27
Devdattahack1015-Nov-11 12:27 
AnswerRe: How To Create Classic Menu in C# desktop apll. Pin
PIEBALDconsult15-Nov-11 13:42
mvePIEBALDconsult15-Nov-11 13:42 
Questionc# image pixel shrink Pin
Member 773856115-Nov-11 8:43
Member 773856115-Nov-11 8:43 
AnswerRe: c# image pixel shrink Pin
Peter_in_278015-Nov-11 13:23
professionalPeter_in_278015-Nov-11 13:23 
GeneralRe: c# image pixel shrink Pin
Smithers-Jones15-Nov-11 22:23
Smithers-Jones15-Nov-11 22:23 
AnswerRe: c# image pixel shrink Pin
BillWoodruff16-Nov-11 14:54
professionalBillWoodruff16-Nov-11 14:54 
QuestionQuick way to add block comments? Pin
jclark239b915-Nov-11 6:55
jclark239b915-Nov-11 6:55 
AnswerRe: Quick way to add block comments? PinPopular
OriginalGriff15-Nov-11 9:37
mveOriginalGriff15-Nov-11 9:37 
You can create your own snippets. Create a new file in VS (from the File menu, New, XML file is fine.)
XML
<?xml version="1.0" encoding="utf-8" ?>
<CodeSnippets  xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
    <CodeSnippet Format="1.0.0">
        <Header>
            <Title>CommentBlock</Title>
            <Shortcut>CB</Shortcut>
            <Description>Code snippet for Comment block</Description>
            <Author>Microsoft Corporation / Paul Griffin modified</Author>
            <SnippetTypes>
                <SnippetType>Expansion</SnippetType>
                <SnippetType>SurroundsWith</SnippetType>
            </SnippetTypes>
        </Header>
        <Snippet>
            <Declarations>
                <Literal>
                    <ID>comment</ID>
                    <ToolTip>comment block</ToolTip>
                    <Default>MyComment</Default>
                </Literal>
            </Declarations>
            <Code Language="csharp">
                <![CDATA[/* $selected$ */$end$]]>
            </Code>
        </Snippet>
    </CodeSnippet>
</CodeSnippets>
Save the file in the folder:
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC#\Snippets\1033\Visual C#
As CommentBlock.snippet
It will now appear in the Surround With list for C# files.

It's a bit rough and ready - it's the first one I have done - but it works.

[edit]Typos in the introduction text - OriginalGriff[/edit]
[edit]I have re-worked this a little, and posted it as a Tip/Trick: Adding a Snippet to Visual Studio[^] - OriginalGriff[/edit]
Ideological Purity is no substitute for being able to stick your thumb down a pipe to stop the water


modified 16-Nov-11 6:12am.

GeneralRe: Quick way to add block comments? Pin
jclark239b915-Nov-11 10:26
jclark239b915-Nov-11 10:26 
AnswerRe: Quick way to add block comments? Pin
BobJanova16-Nov-11 3:13
BobJanova16-Nov-11 3:13 
GeneralRe: Quick way to add block comments? Pin
jclark239b918-Nov-11 5:54
jclark239b918-Nov-11 5:54 
QuestionCircular dependency between classes Pin
vinayvraman15-Nov-11 6:34
vinayvraman15-Nov-11 6:34 
AnswerRe: Circular dependency between classes Pin
PIEBALDconsult15-Nov-11 6:46
mvePIEBALDconsult15-Nov-11 6:46 
AnswerRe: Circular dependency between classes Pin
Clive D. Pottinger15-Nov-11 6:54
Clive D. Pottinger15-Nov-11 6:54 
GeneralRe: Circular dependency between classes Pin
harold aptroot15-Nov-11 7:01
harold aptroot15-Nov-11 7:01 
GeneralRe: Circular dependency between classes Pin
vinayvraman15-Nov-11 7:52
vinayvraman15-Nov-11 7:52 
GeneralRe: Circular dependency between classes Pin
CDP180216-Nov-11 0:41
CDP180216-Nov-11 0:41 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.