The command button takes its colors from the Windows default colors. That is, except for the text on the button. You could always add a white bitmap to the button.
Another thing you could do is create your own class using a shape with a label in it and perform functions in the click event of the shape.
Dave S.
The only way I can think of is to create a colored bitmap, and use that in the picture property. You may need to add text to the bitmap if you need text on it. Mike Gagnon
If you want to get the best response to a question, please check out FAQ184-2483 first
1. You cannot directly change the command buttons back color.
2. There is a work around worth thinking, if the events you need to process are available for the text box.
Fox example..
a. Drop a text box in your form.
b. Set its properties as given below..
Name = "Add"
DisabledBackColor = RGB(255,255,128) && yellow
** you can set it to what ever you want.
ReadOnly = .t.
c. In the click event of the Text box put your click event code.
d. In the KeyPressEvent of the Text box.. add the code..
This.Click()
But this is not helping you with hot keys. As i mentioned lot of limitations .. but if the requirement is small go ahead....
3. However.. the correct approach will be to RollOut your own Jpg or BMP and use that in the Picture class of the command Button. If you want an Example.. provide me your email. I will send one sample BMP whcih you can put in your command Button as the picture property and view the form..
Hope this helps you ramani
(Subramanian.G),FoxAcc, ramani_g@yahoo.com
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.