PRB: Cannot Generically Set DisabledForeColor on Some ObjectsID: Q147307 3.00 3.00b WINDOWS kbtool kbprb The information in this article applies to:
SYMPTOMSIt is possible to set the DisabledForeColor of some objects generically, rather than using an explicit value. One way to do so is to set the DisabledForeColor property to =This.ForeColor to make the DisabledForeColor of most objects identical to the current ForeColor. However, this has no effect on check boxes or on combo boxes that have a Style property of 2-DropDown List.
WORKAROUND
Combo Box Objects1. Set the Style property of the combo box to 0-Dropdown Combo. 2. Set the DisabledForeColor property of the ComboBox to:
3. To make the combo box behave as if its Style property were 2-Dropdown
Now the combo box will behave as if its Style property were 2-Dropdown List
with a DisabledForeColor identical to the ForeColor.
Check Box Objects1. When you disable objects on the form, do not disable any check boxes. 2. Create a Custom property of the form to indicate whether objects are 3. In the GotFocus and MouseUp events of the check box(es), place the
Now the check box always has the same ForeColor but can be disabled by
changing a custom property on the form such as IsEnabled to false.
STATUSMicrosoft is researching this behavior and will post new information here in the Microsoft Knowledge Base as it becomes available.
MORE INFORMATION
Steps to Reproduce Behavior1. Create a new form, and place a combo box and check box on the form. 2. Set the combo box Style property to 2-Dropdown List, the RowSourceType 4. Set the DisabledForeColor property of both the combo box and the check
5. Place a command button on the form. Give it a caption of Disable, and
6. Run the form, click the combo box, and choose an item from the list.
Additional reference words: 3.00 3.00b VFoxWin
KBCategory: kbtool kbprb
KBSubcategory: FxtoolFormdes
|
Last Reviewed: February 24, 1996 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |