yabbadabba
New Member
- Joined
- Mar 26, 2011
- Messages
- 20
Hi guys,
I have a userform with a multipage on it. On each multipage (3 of) there are several text boxes on each page. I have a code on page3 that will change the background colour if a criteria is met, however it also changes the background colour on the textboxes on the other pages.
Here is my code:
For Each ctrl In Me.Controls
If TypeOf ctrl Is msforms.TextBox Then
If ctrl.Value = "." Then ctrl.BackColor = RGB(255, 255, 255)
End If
Next ctrl
What i would like is that the textboxes on page3 of the multipage change colour only and not the text boxes on the other pages.
Any help would be appreciated. Thanks
I have a userform with a multipage on it. On each multipage (3 of) there are several text boxes on each page. I have a code on page3 that will change the background colour if a criteria is met, however it also changes the background colour on the textboxes on the other pages.
Here is my code:
For Each ctrl In Me.Controls
If TypeOf ctrl Is msforms.TextBox Then
If ctrl.Value = "." Then ctrl.BackColor = RGB(255, 255, 255)
End If
Next ctrl
What i would like is that the textboxes on page3 of the multipage change colour only and not the text boxes on the other pages.
Any help would be appreciated. Thanks