Hi everyone,
I have this code below and I was wondering if there is a shorter code for that? It's just a snippet and the real userform has more than 50 Buttons.
If I click the command button it will change the font color of all commandbuttons on the userform.
Private Sub CommandButton1_Click()
CommandButton2.ForeColor = RGB(255,255,255)
CommandButton3.ForeColor = RGB(255,255,255)
CommandButton4.ForeColor = RGB(255,255,255)
CommandButton5.ForeColor = RGB(255,255,255)
CommandButton6.ForeColor = RGB(255,255,255)
CommandButton7.ForeColor = RGB(255,255,255)
CommandButton8.ForeColor = RGB(255,255,255)
CommandButton9.ForeColor = RGB(255,255,255)
CommandButton10.ForeColor = RGB(255,255,255)
End Sub
Thank you.
Bookmarks