Multiple lines in msgbox

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

Guest

I have the following code
MsgBox "Please select a Form or Report", 64, "Incomplete Request"

I would like to put more text in the message but I want it on two lines
rather than just 1 long line.

example: "Please select a Form or Report"
"from the list below."

rather than: "Please select a Form or Report from the list below."

Any suggestions???
 
Hi Ray,
put vbCrLf between the 2 lines
i.e MsgBox "Please select a Form or Report" & vbCrLf & "from the list
below.", 64, "Incomplete Request"
 
Ray,
To move to the next line in a message box you need the & VbCrLF. See sample
below.

Private Sub Command0_Click()
Dim s As String
Dim dr As Integer
s = "Please Select A Form Or Report" & vbCrLf & "From The List Below"
dr = MsgBox(s, 64, "Incomplete Request")
End Sub

HTH,
Chris
 

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