FIX: Cannot See ListView and TreeView Check Boxes When You Use the High Contrast Black Color Scheme

This article has been archived. It is offered "as is" and will no longer be updated.
When you use the TreeView control or the ListView control in Visual Basic 6.0, and you select the CheckBoxes option, you cannot see these check boxes under some Windows color schemes such as High Contrast Black. The TreeView and ListView controls are from Microsoft Windows Common Controls 6.0 (Mscomctl.ocx).
This behavior occurs because the mask color for these controls is hard-coded. Windows uses the mask color to draw the check boxes. This hotfix addresses the problem by using a mask color that is based on the current Windows color scheme.
A supported fix is now available from Microsoft, but it is only intended to correct the problem described in this article. Only apply it to systems that are experiencing this specific problem. This fix may receive additional testing to further ensure product quality. Therefore, if you are not severely affected by this problem, Microsoft recommends that you wait for the next Visual Studio 6 Service Pack 6 that contains this hotfix.

To resolve this problem immediately, contact Microsoft Product Support Services to obtain the fix. For a complete list of Microsoft Product Support Services phone numbers and information about support costs, visit the following Microsoft Web site: Note In special cases, charges that are ordinarily incurred for support calls may be canceled if a Microsoft Support Professional determines that a specific update will resolve your problem. The usual support costs will apply to additional support questions and issues that do not qualify for the specific update in question.

The English version of this fix has the file attributes (or later) that are listed in the following table. The dates and times for these files are listed in coordinated universal time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.
   Date         Time   Version    Size       File name   ------------------------------------------------------   20-Jan-2003  22:42  1,062,160  Mscomctl.ocx

Microsoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article.

Steps to Reproduce the Behavior

  1. Create a new Visual Basic 6.0 Standard EXE project. By default, Form1 is created.
  2. On the Components menu, click Projects, and then add a reference to Microsoft Windows Common Controls 6.0 (Mscomctl.ocx).
  3. Add a ListView control (ListView1) and a TreeView control (TreeView1) to Form1.
  4. For each control, right-click the control, click to select the CheckBoxes option, and then click OK.
  5. Add the following code to Form1:
    Private Sub Form_Load()    TreeView1.Nodes.Add , , , "Test"    ListView1.ListItems.Add , , "Test"End Sub
  6. Run the project. Verify that the check boxes in both controls are visible, and that you can click to select them.
  7. Open the Windows Display Properties dialog box. To do this, right-click the desktop, and then click Properties. (You can also do this by opening Control Panel, and then double-clicking Display.)
  8. Click the Appearance tab, select High Contrast Black in the Scheme list box, and then click OK.
  9. Run the project again. Note that you cannot see the check boxes.

Article ID: 813416 - Last Review: 02/27/2014 21:16:37 - Revision: 2.2

  • Microsoft Visual Basic 6.0 Professional Edition
  • Microsoft Visual Basic 6.0 Enterprise Edition
  • Microsoft Visual Basic 6.0 Learning Edition
  • the operating system: Microsoft Windows XP
  • kbnosurvey kbarchive kbbug kbfix kbqfe kbaacc kbvbp600fix KB813416