How can I program a message box to open when a user opens and exc.

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How can I program a message box to open when a user opens and excell file.

Ie. When a user selects to open a file a command box opens with the messge
"Please note this file is good for ..." wtc. The user then clicks ok to
continue to the opened work book.
 
Private Sub Workbook_Open()
msgbox "Please note this file is good for . . . "
End Sub

go into the VBE and go to the Thisworkbook entry in the Project explorer.
double click on this an you will get the code module for Workbook level
events. In the left dropdown as the top choose Workbook and from the right
choose Open. Add the line for the message box.

http://ww.cpearson.com/excel/events.htm Chip Pearson's page on events.
 

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

Back
Top