Comment Format

accessman2

Registered User.
Local time
Today, 07:18
Joined
Sep 15, 2005
Messages
335
Hi,

Every time, when I write the comment in the modules, I will add ' (apros) at the begining of each line such as

' This is function 1
' This function calculate sum of the numbers
' And, it will returns the value back to form

Do we have a comment symbol for paragraph?
For example:

/* ***************************
This is funtion 1
This function calclate sum of the numbers
And, it will returns the value back to form
****************************/

Do we have the symbol /* */ to make the paragraph?
 
re:

Hi,
as far as I know the single quote (apostrophe) character is the only comment character in VBA which comments out the whole line.
HTH
Good luck
 
if you comment out a msgbox with continuation chars, the whole thing is commented out with a single apostrophe

so maybe you could do what yuo want with continuations
 
Hello,

While there is no other special character to comment out paragraphs, you could use an underscore at the of the sentence and begin a new line of comment with out having to use the apostrophe...


Code:
     [COLOR="SeaGreen"]'// test to see if we have a valid file name, _ 
         then, test for something else, but remember that _ 
         other things must... blah, blah, blah[/COLOR]
     IF System.File.Exists(strFile) Then
         '// Do something meaninful here and move on _ 
             to the next piece of code
     Else
     End If
 
Also, in the module editor, right click on the toolbars and turn on the Edit toolbar. In there, you'll see two buttons with dark blue and cyan colored lines in them. Those are the Comment Block and Uncomment Block buttons. With them you can select an entire range of lines in your module, and then either comment or uncomment the entire selection with one click.
 
Also, in the module editor, right click on the toolbars and turn on the Edit toolbar. In there, you'll see two buttons with dark blue and cyan colored lines in them. Those are the Comment Block and Uncomment Block buttons. With them you can select an entire range of lines in your module, and then either comment or uncomment the entire selection with one click.

Yes but living with the
Compile error:
Expected: end of statement

Error dialog after each carriage return (without apostrophe) makes simply placing the apostrophe at the beginning of each line a small task indeed.
 

Users who are viewing this thread

Back
Top Bottom