Change row in a Visual Basic messagebox
Hi,
How do you change row in a msgbox in Visual Basic? For instance if you would like to cut a sentence into two rows, so instead of the msgbox showing: "A long sentence in just one piece" It shows "A long sentence but in two pieces" Might be a bit silly question but in the hunt for pedagogy and efficiency... Thanks /Stefan |
Change row in a Visual Basic messagebox
Stefan,
MsgBox "A long sentence " & vbNewLine & "but in two pieces" NickHK "svai" wrote in message ... Hi, How do you change row in a msgbox in Visual Basic? For instance if you would like to cut a sentence into two rows, so instead of the msgbox showing: "A long sentence in just one piece" It shows "A long sentence but in two pieces" Might be a bit silly question but in the hunt for pedagogy and efficiency... Thanks /Stefan |
Change row in a Visual Basic messagebox
Hi Stefan
Try inserting a line feed (or CrLf this sometimes gives a square box though) "A long sentence " & chr(10) & "in just two pieces" Regards -- Tony Green "svai" wrote: Hi, How do you change row in a msgbox in Visual Basic? For instance if you would like to cut a sentence into two rows, so instead of the msgbox showing: "A long sentence in just one piece" It shows "A long sentence but in two pieces" Might be a bit silly question but in the hunt for pedagogy and efficiency... Thanks /Stefan |
Change row in a Visual Basic messagebox
Looks like there are quite a few methods of doing this, because I
always just put vbcrlf. as in ..."A long sentence " & vbcrlf & "in just two pieces" Duncan ADG wrote: Hi Stefan Try inserting a line feed (or CrLf this sometimes gives a square box though) "A long sentence " & chr(10) & "in just two pieces" Regards -- Tony Green "svai" wrote: Hi, How do you change row in a msgbox in Visual Basic? For instance if you would like to cut a sentence into two rows, so instead of the msgbox showing: "A long sentence in just one piece" It shows "A long sentence but in two pieces" Might be a bit silly question but in the hunt for pedagogy and efficiency... Thanks /Stefan |
Change row in a Visual Basic messagebox
Duncan,
Debug.Print vbNewLine = vbCrLf NickHK "Duncan" wrote in message ups.com... Looks like there are quite a few methods of doing this, because I always just put vbcrlf. as in ..."A long sentence " & vbcrlf & "in just two pieces" Duncan ADG wrote: Hi Stefan Try inserting a line feed (or CrLf this sometimes gives a square box though) "A long sentence " & chr(10) & "in just two pieces" Regards -- Tony Green "svai" wrote: Hi, How do you change row in a msgbox in Visual Basic? For instance if you would like to cut a sentence into two rows, so instead of the msgbox showing: "A long sentence in just one piece" It shows "A long sentence but in two pieces" Might be a bit silly question but in the hunt for pedagogy and efficiency... Thanks /Stefan |
Change row in a Visual Basic messagebox
Ok Nick, I see.....
(I am also a beginner though, entitled to follow the slow meandering path towards enlightenment) Duncan NickHK wrote: Duncan, Debug.Print vbNewLine = vbCrLf NickHK "Duncan" wrote in message ups.com... Looks like there are quite a few methods of doing this, because I always just put vbcrlf. as in ..."A long sentence " & vbcrlf & "in just two pieces" Duncan ADG wrote: Hi Stefan Try inserting a line feed (or CrLf this sometimes gives a square box though) "A long sentence " & chr(10) & "in just two pieces" Regards -- Tony Green "svai" wrote: Hi, How do you change row in a msgbox in Visual Basic? For instance if you would like to cut a sentence into two rows, so instead of the msgbox showing: "A long sentence in just one piece" It shows "A long sentence but in two pieces" Might be a bit silly question but in the hunt for pedagogy and efficiency... Thanks /Stefan |
Change row in a Visual Basic messagebox
Thanks a bunch everyone! /Stefan
"Duncan" wrote: Ok Nick, I see..... (I am also a beginner though, entitled to follow the slow meandering path towards enlightenment) Duncan NickHK wrote: Duncan, Debug.Print vbNewLine = vbCrLf NickHK "Duncan" wrote in message ups.com... Looks like there are quite a few methods of doing this, because I always just put vbcrlf. as in ..."A long sentence " & vbcrlf & "in just two pieces" Duncan ADG wrote: Hi Stefan Try inserting a line feed (or CrLf this sometimes gives a square box though) "A long sentence " & chr(10) & "in just two pieces" Regards -- Tony Green "svai" wrote: Hi, How do you change row in a msgbox in Visual Basic? For instance if you would like to cut a sentence into two rows, so instead of the msgbox showing: "A long sentence in just one piece" It shows "A long sentence but in two pieces" Might be a bit silly question but in the hunt for pedagogy and efficiency... Thanks /Stefan |
Change row in a Visual Basic messagebox
the truth of that statement is OS system dependent. vbNewline < vbCrLf on
a MAC for example. vbNewline will always be appropriate for this question. -- Regards, Tom Ogilvy "NickHK" wrote: Duncan, Debug.Print vbNewLine = vbCrLf NickHK "Duncan" wrote in message ups.com... Looks like there are quite a few methods of doing this, because I always just put vbcrlf. as in ..."A long sentence " & vbcrlf & "in just two pieces" Duncan ADG wrote: Hi Stefan Try inserting a line feed (or CrLf this sometimes gives a square box though) "A long sentence " & chr(10) & "in just two pieces" Regards -- Tony Green "svai" wrote: Hi, How do you change row in a msgbox in Visual Basic? For instance if you would like to cut a sentence into two rows, so instead of the msgbox showing: "A long sentence in just one piece" It shows "A long sentence but in two pieces" Might be a bit silly question but in the hunt for pedagogy and efficiency... Thanks /Stefan |
All times are GMT +1. The time now is 06:03 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com