![]() |
Questions? Call us 302-234-9857, 8AM to 10PM U.S. East Coast time 7 days a week |
|
|
|
How to document your macro code
and why use the Code Documentor for Microsoft® Excel® There are several key steps one can do to document macro code and to make it more understandable, both when you are first creating it and when you look at it again months later:
Memory usage: Code Documentor is a VBA add-in. Such add-ins use less memory than COM add-ins and have 5-10 open at a time typically has little to no effect on Excel memory. Use of the Add-In Information Lister to manage add-ins, removing those not needed and then re-installing when needed is best. The Code Documentor provides a list of the sheets, userforms, and modules in your project, how many procedures (macros) in each, and how many lines of code. It does not list the individual macro names or what variables are being used when calling them. Nor does it list any of the comments found in the macros. The key benefit is knowing if your lines of code in a module is exceeding 600 lines. Code that is more than 600 lines has sometimes been know to become corrupt. It is best to keep modules below 600 lines, and always below 1000 lines. To use the Code Documentor after installing, open your workbook or add-in containing your code. If the code is password protected, access the project so that the code is viewable. Then, do the following:
To use the Code Documentor after installing :
|
|
| Copyright 2010 Add-ins.com LLC, all rights reserved. Spreadsheet Assistant is a registered trademark of Add-ins.com LLC. Microsoft, Excel and the Office logo are trademarks or registered trademarks of Microsoft Corporation in the United States and/or other countries. |