VBScript question: Multiline comments?

I know how to do a single-line comment in VBScript:

'This is a comment

Usually when I do multiple lines I just begin each line with a single quote:

'This is comment line 1
'This is comment line 2
'...
'Comment N...


Is there a multiline comment format (as found in other languages)?

As in:

/*Comment line 1
Line 2
Line 3
Line 4
Line 5  */

(Everything between the /* and the */ is marked as a comment.



Just wondering if VBScript has the same sort of thing, and I missed it.


Tom
LVL 5
Tom KnowltonWeb developerAsked:
Who is Participating?
 
kingsfan76Commented:
not that I know of.  I don;t think there is a direct way.
you can sort of use the html comment to comment out a section:
<%
........  'some codes
%>
<!--
<%
........  'comment out codes
%> -->

in VB.NET the syntax for comment out a section of codes is added.
0
 
GaryCommented:
No you have to comment each line out or use comment tags like this
<!--
sadfds
sdaf
dsf
-->
0
 
IguanasanCommented:
VB Script does not have multi-line comments.  Either use the single quote ' or the REM statement.

' This is my comment
REM And this is a comment too.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.