Changing Command button colors with vba

jerryczarnowski

Registered User.
Local time
Yesterday, 17:15
Joined
Jan 29, 2012
Messages
31
Hello, I have the following chunk of code from 2010 and would like to know the equivalent in 2007.

Private Sub cmdPallet32_Click()
' show pallet button green - represents active pallet
Dim lngWhite As Long, lngGreen As Long
lngGreen = RGB(34, 177, 76)
lngWhite = RGB(255, 255, 255)
cmdPallet32.BackColor = lngGreen
cmdPallet32.ForeColor = lngWhite ' ForeColor is actually the font color
End Sub

Is there an equivalent property in 2007 for BackColor, FontColor, and Border color for a command button? Do you set it the same way as 2010 like the code above?

Thanks, Jerry
 

Users who are viewing this thread

Back
Top Bottom