I have the feeling this question probably has an easy answer, I just can't find it anywhere. And yes, I have looked - in several places actually!
I want to set up a snippet of code as follows:
CODE
If Msgbox("Line 1 _
Line 2 _
Line 3 _
Line 4 Do you want to do this?", vbQuestion + vbYesNo, "MsgBox Title") = vbYes Then
do X
Else
do Y
End If
Line 2 _
Line 3 _
Line 4 Do you want to do this?", vbQuestion + vbYesNo, "MsgBox Title") = vbYes Then
do X
Else
do Y
End If
I am not pulling any variables into the MsgBox content, so there are no obvious natural breakpoints. The line breaks are for my convenience in reading the code, not because I want to break the line on the screen in that particular place. (so vbCrLf won't help me)
I've tried ending the lines with _ and & _ and neither seems to work. I just get the "Expected list separator or )" message.
I know this is just a dumb formatting thing. What am I missing?
Thanks all!
nkstrou