VBA Pop up/message box formatting

BrianG86

Board Regular
Joined
Nov 12, 2013
Messages
135
Hi

I have a message box that will come up once my Macro is complete. It's just there to let the user know that they can take the next step. Just for aesthetic purposes, I want the formatting to be better. Its currently all crammed in, I would like it to be on separate lines after each full stop and possibly to be centred in the message box.

Is this possible? This is my current code.

Code:
 MsgBox "The Macro is now complete.  Please email this to xxxl@xxx.com, and upload the CSV file to CaseBlocks.  Click OK to continue"
 
Try

Code:
MsgBox "The Macro is now complete." & vbCrLf & _
"Please email this to xxxl@xxx.com, and upload the CSV file to CaseBlocks." & vbCrLf & _
"Click OK to continue"
 
Upvote 0
That's great, thanks for the quick reply.

Is there any way I could have this centred in the box, rather that left to right?
 
Upvote 0
Sorry, no not with a standard Msgbox.

You could try padding with spaces at the left of the sentence - a bit trial and error.
 
Upvote 0

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