Juanderful1
New Member
- Joined
- Dec 26, 2002
- Messages
- 12
I am trying to add a new control to the File Pull Down menu and not having much luck.
I am using the code below, it seems simple. But when I try to run it I get this error message :
Error : Object Variable or With Block Variable not set
Public Sub NewThing()
Dim x
Set x = CommandBars("Worksheet Menu Bar").Controls("File").Controls.Add(Type:=msoControlPopup)
End Sub
Anyone know what I am doing wrong??
I am using the code below, it seems simple. But when I try to run it I get this error message :
Error : Object Variable or With Block Variable not set
Public Sub NewThing()
Dim x
Set x = CommandBars("Worksheet Menu Bar").Controls("File").Controls.Add(Type:=msoControlPopup)
End Sub
Anyone know what I am doing wrong??