Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi guys,
This is driving me insane!!! I'm trying to have the text of all of the controltiptext properties on a userform to be the same as the caption property of the label (there's loads of labels). It seemed like it should have been easy, but after much trial and error I've managed to come up with the following (which I don't quite follow) and feels so close, but I'm stumped as to get the caption in the Sub Change_Labels_UserForm() Dim oVBProj, oVBComp As Object Dim ctl As Control Set oVBProj = ThisWorkbook.VBProject On Error Resume Next For Each oVBComp In oVBProj.VBComponents If oVBComp.Type = 3 Then For Each ctl In oVBComp.Designer.Controls If Left(ctl.Name, 5) = "Label" and ctl.ControlTipText = "" Then ctl.ControlTipText = 'caption name Next End If Next End Sub Any ideas? Cheers, JF |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Userform Label | Excel Discussion (Misc queries) | |||
userform label creation | Excel Programming | |||
Flashing UserForm Label | Excel Programming | |||
Change label caption on userForm while code runs | Excel Programming | |||
Userform Label question | Excel Programming |