browse by category or date

I was just browsing through MSDN website when I noticed something that all this time I considered it very trivial. Apparently in VB, you need to give every line apostrophe (‘) to make that line a comment (I know this). And you can’t use the underscore (_) to continue the comment, you still need to give the apostrophe again in the next line (now that is new).

Very contrast compared to other language such as C# (or other similar language in that matter, like C/C++, Java), you can use double slashes (//) to start a comment. To make multiple-line comment, you need to start it with /* and end it */

The comparison becomes a moot point if you are using Visual Studio. You can easily select the lines, and press Ctrl+K+C to comment it, and Ctrl+K+U to uncomment the selected lines.

GD Star Rating

About Hardono

Hi, I'm Hardono. I am working as a Software Developer. I am working mostly in Windows, dealing with .NET, conversing in C#. But I know a bit of Linux, mainly because I need to keep this blog operational. I've been working in Logistics/Transport industry for more than 11 years.

4 comments so far

Add Your Comment
  1. I give up with VB, and strict in C#!
    VB, the language I’ve used for 5 years 🙂

  2. well .. I do like C# a lot, but I must compromise since my most projects are using VB.NET ^^’

  3. hye.
    i know what is the method of assigning single line comment in VB.but wht is the method of assigning Multiline Comments in VB?
    can somebody help.
    kindly reply me on mail.

    • Vikas, there’s no way to do such thing in VB.