Simple question about Keyboard shortcut.

  • Thread starter Thread starter Aranis
  • Start date Start date
A

Aranis

Would anyone know how to use a keyboard shortcut so at the end of a method
syntax I can use that shortcut to create the method's pair of { } brackets
?

Thank you much,
Aranis
 
Aranis said:
Would anyone know how to use a keyboard shortcut so at the end of a method
syntax I can use that shortcut to create the method's pair of { }
brackets ?

Thank you much,
Aranis



So you want a macro for Visual Studio that just inserts the string "{ }" at
the cursor location when you press a specific key combination?

Doesn't seem like much of a shortcut...I mean { } is only 3 keystrokes as it
is, or maybe I'm not following your question.
 
Hi Roger, thanks for the reply.

What I am asking is like Sub in VB. At the end of a method declaration,
as soon as you hit the Enter key, VS creates the EndSub for you and the
cursor goes where you need to implement the method code. It would be
mighty nice to have that in C# also where you could just hit the enter key
at the end of the method declaration and have a pair of brackets created
with a line in between them where the cursor is in the right place so you
could just start writing the code.

I almost believe that there must be a flag that can be set in VS to have
this thing activated.

Aranis
 
Back
Top