How can I make a msgbox multiline?
like write something on one line and
another on the next...?...
Smile - somewhere its helping someone.
Printable View
How can I make a msgbox multiline?
like write something on one line and
another on the next...?...
Smile - somewhere its helping someone.
MsgBox "this is line one" & vbNewLine & "this is line 2"
David Paulson
thank you sooooo much! is there a way to center text on a msgbox also?
Smile - somewhere its helping someone.
I whipped up a function for you
option Explicit
private Sub Form_Load()
MsgBox CenterString("this is line one") & vbNewLine & CenterString("this is line 2")
End Sub
public Function CenterString(str as string) as string
str = Space((25 - len(str)) / 2) & str & Space((25 - len(str)) / 2)
CenterString = str
End Function
David Paulson
thank you VERY much for ur help
honestly tho, i dont think i will be able to use that because I havta do this proj for a school proj and im not sure we're allowed to use things we havent learned about and we havent learned about "Public ..." stuff....
But thank you ever so much!!!
Smile - somewhere its helping someone.