Comment code

Is there a way in VB to comment out a block of code without commenting out each individual line.
Who is Participating?
agrillageConnect With a Mentor Commented:
Right click on any button and choose customize. Choose the commands tab. Select Edit from the categories. Find comment block and uncomment block and then drag them onto your toolbar.
Or you could download my addins here
VBIDEUtils :
|*  VBIDEUtils 1.3 by Thierry Waty


VBIDEUtils is a great add-in for VB 5.0 and VB 6.0. With
this add-in, you can do :
      - Code Repository
            - Store VB Code, Classes, Projects
            - Store files
            - Store HTML pages
            - Store HTML links
            - Search through all the database
            - Store VB Scripts / Java Scripts
            - .....
      - Indent easily your code
      - Add comment to your modules and procedures
      - Find the corresponding ending block instruction
      - Know all the APIs error name
      - Clear the debug Window
      - Change easily the taborder of all your controls

Target platforms

Visual Basic 5.0, Visual Basic 6.0

You need Microsoft® Visual Basic® 5.0 Service Pack 3 or higher in order to
run properly. If you need a version without any service pack, it is possible,
you have to contact me in that case.


With this great add-ins, you will be able to :
    - Store all your VB libraries (VB Script, JavaScript...) in categories
    - Identify immediately the type of the stored item
    - You can store HTML page in the database
    - You can store HTML links to page, files...
    - Store files : Zip files, VB projects, bas files, class files...
    - The code is colorized
    - Print nicely the code
    - Search through all the code easily
    - Paste files from the Explorer
    - See HTML files
    - Browse Internet offline
    - Comment your procedure, module, code directly in your VB IDE
    - Indent the code in the procedure, module project to
       have standard indentation
    - Show the API error string related to an API error number
    - Clear the debug window when it is full of debugging information
    - Change easily the taborder of all your controls
    - Find the corresponding ending block instruction. By this I mean that
       you can find the corresponding "End If" for a particular "If",
       "End Select" for a "Select", "Next" for a "For", "Loop"
       for a "Do While"... and of course vice-versa
    - ... Many other features
The use of this add-in is very simple and very useful.

            J U S T   T R Y   I T.


- Many other possibilities in the future
        -> Add error trapping in all your code
            to build error proof applications
        -> Documentation of your code
      -> Better search
      -> Increased database
      -> C++, Java, Delphi, Windev database
      -> Colorization of other languages
      -> ...

This add-ins is changing often in order to be the best thing on the market.
You, users, could help me telling me your needs and what could be useful
for your work.

Feedback / Register

The shareware version contains only links to HTML pages, if you want to store
those page as HTML, you have to refresh (see in the tools menu).
Some code is not present in the shareware version. All this code is present
in the registered version.

When you register, the about disappear, and you will receive my latest complete
VB Code library containing thousands of VB code line. That Code library
contains VB Code (bas files, classes...), articles, OCX, HTML pages, link
to the best VB knowledge on the internet.

Tell me what you like, what you don't like, and for that matter, if you think
the tool is worth a shareware fee. See the prices below :

   VBIDEUtils Full database licence :                     $99
      - You will receive one licence with the full code library
      See at

   VBIDEUtils Full Site corporate database licence :         $399
      - You will receive a licence for use in all your company
          with the full code library
      See at

   VBIDEUtils Full Source Code + database licence :     $699
      - You will receive one licence with the full code library
          and all the code of the VBIDEUtils
      If you are using Credit Card, you can do the registration online on
      See at

   VBIDEUtils database update :                           $30
      - You will receive the latest code library, which changes every day.
        You can buy as many update as you want.
      See at

If you prefer to send me the registration fee directly by mail,
you may send money, payable in US funds, or your in local currency
to the following address:

-----   Waty Thierry
-----   Rue de l'agriculture, 56
-----   1030 Brussels
-----   Belgium

E-Mail   :
Web Site :

System Requirements
You need a computer running Microsoft® Windows 95/98® or Microsoft® Windows NT®.
Microsoft® Visual Basic® 5.0 (Service Pack 3) or Higher with all the runtime
installed and an installation of Internet Explorer 3.0 or 4.0 or higher installed.


Just start the program "Install.EXE". Once it is done, start your VB,
you have a new toolbar, and new items in the Edit Menu and in the contextuel
menu of your Code window.


You need to install the Service Pack 3 of VB 5.0 for VB 5.0 in order to run
correctly this version. If you don't have installed SVP3, consider installing the
Service Pack 3 of Microsoft. It is free. you can find it on the web
site of Microsoft.

If you have problems during the installation or the execution of
this add-in, this is probably due to the fact that you didn't
have installed all the DLL from your VB 5.0 or VB 6.0

Try install all the DLL (including the DAO). If the problem still
exists, contact me and I will solve the problem with you.


Thank you for taking the time to download VBIDEUtils.
I hope you find it to be of use in your development efforts.
Please let me know how it can be made better!

This product is licenced to you pursuant to the terms of the licence
agreement included with the original software, and is protected
by copyright law and international treaties.  
Unauthorized reproduction or distribution may result in severe civil
and criminal penalties, and will be prosecuted to the maximum extent
possible under the law.

Other products

I have also developped other products. They are all on my web site.
Here is the list of them :
        - Print Preview OCX for VB 5.0, VC++, VB 4.0 32 bits, Office...
        - Print Preview OLE 2 Control for VB 3.0, VB 4.0 16 bits
        - TBCalendar OCX for VB 5.0, VC++, VB 4.0 32 bits, Office...
        - Logger OCX for VB 5.0, VC++, VB 4.0 32 bits, Office...
        - INIEditor : Editor of INI files
        - Jolly OCX 1.0 card game for VB 5.0, VC++, VB 4.0 32 bits, Office...
        - Rotate label OCX 1.0 for VB 5.0, VC++, VB 4.0 32 bits, Office...


*Version       *Date             *Comments
*Version 1.1   *19 December 1998 * First release
*Version 1.2   *13 January 1998  * Added the possibility to change the taborder
*              *                 *  of all your controls
*              *                 * Added the possibility to add simple comments
*              *                 * Corrected a little minor bug when commenting
*              *                 *  out some code
*Version 1.3   *19 January 1998  * Added the possibility to find the
*              *                 *  corresponding ending block instruction
*              *                 * Some little bugs corrected
*              *                 *


Visual Basic, Windows, Windows NT, Windows 95, Windows 98, and Windows 3.11
are all registered trademarks of Microsoft Corporation.

                        ( O   O )
       Have you ever danced with the devil by the pale moonlight!!!

boyntontAuthor Commented:
Thanks much
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.