lezawang
Well-known Member
- Joined
- Mar 27, 2016
- Messages
- 1,805
- Office Version
- 2016
- Platform
- Windows
Hi
I want to change the background color of a userform when a user click anywhere inside the form. Change the color different from previous one whenever user click on the form. I tried the following code but did not work. Any help would be very much appreciated.
ps: &H0080FF80& is the current color code of the userform's background color property.
I want to change the background color of a userform when a user click anywhere inside the form. Change the color different from previous one whenever user click on the form. I tried the following code but did not work. Any help would be very much appreciated.
Code:
Private Sub UserForm_Click()
'the name of the form is myform
myform.BackColor = myform.backColor + 1
End Sub
ps: &H0080FF80& is the current color code of the userform's background color property.
Last edited: