dialog box to pop up after macro is complete

nabeel151

New Member
Joined
Aug 11, 2010
Messages
4
The macro I have already put in automatically emails the excel file to an email address.

What I need:

Once the button is pushed, I just want a dialog box to pop up and say, "Your Inquiry has been submitted to....."

Then I would like the excel sheet to automatically close.
 

Excel Facts

Can you sort left to right?
To sort left-to-right, use the Sort dialog box. Click Options. Choose "Sort left to right"
Hi

Use the below for your dialog box

msgbox("Your Inquiry has been submitted to.....")

And the below to close your workbook

ActiveWorkbook.Close False
' closes the active workbook without saving any changes

ActiveWorkbook.Close True
' closes the active workbook and saves any changes

ActiveWorkbook.Close
' closes the active workbook and lets the user decide if
' changes are to be saved or not
 
Upvote 0

Forum statistics

Threads
1,214,808
Messages
6,121,684
Members
449,048
Latest member
81jamesacct

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top