View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
JulieD JulieD is offline
external usenet poster
 
Posts: 618
Default Can't get Workbook_Open event to work

Hi

you'll need to check that your security settings are set to medium (or
lower - however, not recommended) - tools / macro / security and then choose
enable macros if prompted.

Cheers
JulieD

"M Smith" wrote in message
...
Newbie question. I'm having a problem in Excel trying to get the
Workbook_open event to fire. I have opened up a the Visual Basic Editor
from Excel and from the Project Explorer, under VBAProject (Book2.xls), I
clicked on ThisWorkbook. This is the code I want to fire...

Private Sub Workbook_Open()
MsgBox "Hello, today's date is " & Format(Date, "ddd d mmm yyyy")
End Sub

After I save it and close Excel, I open up the Book2.xls again and no
message box is displayed. What am I doing wrong.

I'm using Excel 2000 SR-1 on Windows 2000.
Thanks