General information
Title:
Combo disabledbackcolor problem
Using VFP8, I have a combo within a container class and I would like the disabledback color of the combo the same as the form background. As there is no combo.backstyle (ie. opaque/transparent) property, I have the following code in my baseclass combo.init...
IF TYPE('this.Parent.BackColor') # 'U'
this.DisabledBackColor = this.Parent.BackColor
ENDIF
The container.backstyle property is set to 0 (transparent).
The problem is that when the combo is disabled it has the container's background color, not the required form background color (although the container background is transparent). I guess this is because the combo.init fires before the container has set it's background color to that of the form, and doesn't re-adjust when the container background color changes (a good case for a combo.load() event?)
Is there any way around this problem? I know I can manually set combo.disabledbackcolor to that of the form, but I am looking for a more generic solution.
BTW, If I place the combo class directly on the form (ie. not within a container on the form) the disabled background color is correct.
Any help would be appreciated.
Alan
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only