![]() |
message box does not show
Hello this is my message box
Sub Form23() Dim Msg As String Msg = "Complete Attached Form " & vbCrLf Msg = Msg & "Submit Invoice" & vbCrLf Msg = Msg & "Copy your Manager" MsgBox Msg, vbInformation, "Don't Forget" End Sub I want this message to pop up when the work book is opened. right now it only works if I run the macro. thanks |
message box does not show
hi
you probably have the code in a standard module. if you want the msbbox to pop up when the workbook is opened, put in the workbook open module. in the project window(far left) double click thisworkbook then from the left combo of the code window, select this workbook. the workbook_open() should default Regards FSt1 "Marilyn" wrote: Hello this is my message box Sub Form23() Dim Msg As String Msg = "Complete Attached Form " & vbCrLf Msg = Msg & "Submit Invoice" & vbCrLf Msg = Msg & "Copy your Manager" MsgBox Msg, vbInformation, "Don't Forget" End Sub I want this message to pop up when the work book is opened. right now it only works if I run the macro. thanks |
message box does not show
Hi Marilyn,
Try posting the following code in the ThisWorkbook module: '========== Private Sub Workbook_Open() Call Form23 End Sub '<<========== This is workbook event code and should be pasted into the workbook's ThisWorkbook module *not* a standard module or a sheet module: Right-click the Excel icon on the worksheet (or the icon to the left of the File menu if your workbook is maximised) Select 'View Code' from the menu and paste the code. Alt-F11 to return to Excel. --- Regards. Norman "Marilyn" wrote in message ... Hello this is my message box Sub Form23() Dim Msg As String Msg = "Complete Attached Form " & vbCrLf Msg = Msg & "Submit Invoice" & vbCrLf Msg = Msg & "Copy your Manager" MsgBox Msg, vbInformation, "Don't Forget" End Sub I want this message to pop up when the work book is opened. right now it only works if I run the macro. thanks |
All times are GMT +1. The time now is 10:10 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com