Automatic parathesises and braces

D

Denny

I'm going from VB.net.

Is there a way to have VS automatically add braces to methods? Also in VB,
you do not need to add () for a method or function that does not need
parameters. Is there a way to have VS automatically add parathesis to
function calls? This messes me up more than the braces.

Thanks.
 
M

Marc Gravell

Not that I know of... without the brackets, you have a "method group",
which is an essential part of creating a delegate - so the syntax
without the brackets has a partially valid (but different) meaning. To
be honest, I wouldn't worry about it - give it a little while (not
long, honestly) and you'll be bracing and bracketing by default - I
moved to C# from VB6 (a very long time ago, it feels) - and it didn't
take long to get accustomed (but then, I also write ECMA script...).
That said, if I go back to VB I struggle to do ##anything##...

Marc
 
Z

Zhi-Xin Ye [MSFT]

Hi Denny,

Thank you for using Microsoft Managed Newsgroup Support Service, I'm
Zhi-Xin Ye and I will work with you on this issue.

As far as I know the C# IDE does not support this kind of auto-completion.
These features are specific for VB only, as you can see the options under
this path:

(In the IDE)
"Tools" menu -> "Options..." -> "Text Editor" -> "Basic" -> "VB Specific";

There are options like "Automatic insertion of end constructs", "Pretty
listing(reformatting) of code", etc. which are for the auto-completion.

I know how unaccustomed it is when shifting from one language to another. I
have the same experience when I shifted from C# to VB.NET, but it didn't
take long to get accustomed with the new language.

Sincerely,
Zhi-Xin Ye
Microsoft Managed Newsgroup Support Team

Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
(e-mail address removed).

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/en-us/subscriptions/aa948868.aspx#notifications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://support.microsoft.com/select/default.aspx?target=assistance&ln=en-us.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top