The Visual Basic 6 code editor has several handy features to make the programmer's task easier. One is the ability to display different code elements in different colors, making it easier for you read and interpret code. Many programmers don't know that you can customize this feature can be customized, which means you don't have to stay with the default code display scheme.
To change the settings, select Tools | Options and then click the Editor Format tab. The Code Colors list displays the various code categories that you can customize. They are as follows:
Below this list are three drop-down lists that you can use to define the appearance of the selected code component:
For each of these, you can select a color. You can also select Auto, which means that VB doesn't change the specified display attribute from the default.
On the right side of this dialog box, you can view a sample of how the selected settings will appear. You can also turn the margin indicator bar on and off and set the font and size. Note that the latter setting affects all code.
Advance your scripting skills to the next level with TechRepublic's free Visual Basic newsletter, delivered each Friday. Automatically sign up today!



