Missing library or project

C

Craig Wilks

I have the following code for setting up the menu bar upon opening.
However, I keep getting an error missage saying missing project or
library for "mymenubar". How do I solve this error?

Public Sub Workbook_Open()
Dim FSys As Object
Dim resp1 As Integer
Dim abook As Object
Dim IsBookOpen As Boolean

Application.ScreenUpdating = True
Workbooks("Admin.xls").Activate
Worksheets("Index").Activate

MenuBars(xlWorksheet).Reset
MenuBars(xlWorksheet).Activate

Set MyMenuBar = CommandBars.ActiveMenuBar
Set Ordersmenu = MyMenuBar.Controls.Add(Type:=msoControlPopup,
Temporary:=True)
Ordersmenu.Caption = "Orders"

regards

Craig Wilks

*** Sent via Developersdex http://www.developersdex.com ***
 
T

Tom Ogilvy

when you get the error, go into tools=>References in the VBE, and look for a
selected reference marked as MISSING.

Uncheck this or find the reference on disk with the browse button.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top