ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   how can I create a pop-up message whenever a workbook is opened? (https://www.excelbanter.com/excel-discussion-misc-queries/199554-how-can-i-create-pop-up-message-whenever-workbook-opened.html)

twiftshoeblade

how can I create a pop-up message whenever a workbook is opened?
 
I would like to make a message appear in the form of a pop-up, like an input
or error message, whenever a workbook is opened.

Bob Umlas, Excel MVP

how can I create a pop-up message whenever a workbook is opened?
 
Right-click the excel LOGO (near the file menu), select View Code, enter this:
Private Sub Workbook_Open()
Msgbox "Hello, World!"
End Sub
Bob Umlas

"twiftshoeblade" wrote:

I would like to make a message appear in the form of a pop-up, like an input
or error message, whenever a workbook is opened.


Mike H

how can I create a pop-up message whenever a workbook is opened?
 
Hi,

Alt+F11 to open VB editor. Double click 'This Workbook' and paste this in on
the right

Private Sub Workbook_Open()
response = MsgBox("Hello World", vbOKOnly, "My Welcome message")
End Sub

Mike

"twiftshoeblade" wrote:

I would like to make a message appear in the form of a pop-up, like an input
or error message, whenever a workbook is opened.


twiftshoeblade

how can I create a pop-up message whenever a workbook is opene
 
Thanks to both Mike H and Bob Umlas... exactly the result I was seeking.
My target audience, however, is likely to disable macros upon opening the
workbook... anyway to disable that warning?

"Mike H" wrote:

Hi,

Alt+F11 to open VB editor. Double click 'This Workbook' and paste this in on
the right

Private Sub Workbook_Open()
response = MsgBox("Hello World", vbOKOnly, "My Welcome message")
End Sub

Mike

"twiftshoeblade" wrote:

I would like to make a message appear in the form of a pop-up, like an input
or error message, whenever a workbook is opened.


Jim Thomlinson

how can I create a pop-up message whenever a workbook is opene
 
There are t ways around it. One is to have your users set their macro
security to low. The down side is that if a workbook contains a virus then
they will open it without warning and get infected. A better option is to
digitally sign your work. That makes your work into a trusted source and the
book can open without need for the macro security alert... Check out this
link...

http://office.microsoft.com/en-us/he...495551033.aspx
--
HTH...

Jim Thomlinson


"twiftshoeblade" wrote:

Thanks to both Mike H and Bob Umlas... exactly the result I was seeking.
My target audience, however, is likely to disable macros upon opening the
workbook... anyway to disable that warning?

"Mike H" wrote:

Hi,

Alt+F11 to open VB editor. Double click 'This Workbook' and paste this in on
the right

Private Sub Workbook_Open()
response = MsgBox("Hello World", vbOKOnly, "My Welcome message")
End Sub

Mike

"twiftshoeblade" wrote:

I would like to make a message appear in the form of a pop-up, like an input
or error message, whenever a workbook is opened.



All times are GMT +1. The time now is 08:35 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com