Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Can't get Workbook_Open event to work

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



  #2   Report Post  
Posted to microsoft.public.excel.programming
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





Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
excel vba workbook_open event does not work help please newyuppie[_3_] Excel Programming 2 May 21st 04 09:03 AM
Workbook_open Event Bruce Maston Excel Programming 6 April 6th 04 01:19 AM
Workbook_Open Event Squid[_2_] Excel Programming 7 February 8th 04 06:49 PM
WorkBook_Open Event Squid[_3_] Excel Programming 1 February 8th 04 02:45 AM
OnTime event not firing in Workbook_Open event procedure GingerTommy Excel Programming 0 September 24th 03 03:18 PM


All times are GMT +1. The time now is 11:32 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"