Computing.Net > Forums > Programming > msgbox in visual basic

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

msgbox in visual basic

Reply to Message Icon

Name: mahd
Date: March 28, 2004 at 10:54:38 Pacific
OS: XP
CPU/Ram: 933 / 216
Comment:

hello there..

i was woundering if i can enter a msgbox consisting of 2 or more lines in visual basic.

thats the one i'm using now..

MsgBox "Your Input Should Be In Descending Order And Not Over Repeated", vbCritical

and i want it to look like that:

"Check The Following:
Descending order
Over Repeating"

thanx all



Sponsored Link
Ads by Google

Response Number 1
Name: StuartS
Date: March 28, 2004 at 13:51:32 Pacific
Reply:

Try this:

MsgBox "Check The Following:" & vbNewLine & "Descending Order" & vbNewLine & "Over Repeating", vbCritical

Donald

Stuart


0

Response Number 2
Name: MrNiceGuy (by vng2k)
Date: March 28, 2004 at 22:56:22 Pacific
Reply:

vbNewLine (Stuart comments) is the best choice for VB or you can use something like this because it is true for most programming language:

chr(10): Line feed
chr(13): character return

So You may say:

MsgBox "Check The Following:" & chr(10) & chr(13) & "Descending Order" & chr(10) & chr(13) & "Over Repeating", vbCritical

What I am trying to say is vbNewLine = chr(10) & chr(13). So vbNewLine is the choice.


0

Response Number 3
Name: Infinite Recursion
Date: March 30, 2004 at 18:38:45 Pacific
Reply:

On a side note... I use..

... & vbCrLf & ... where I want my line breaks.

IR


0

Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home


Sponsored links

Ads by Google


Results for: msgbox in visual basic

Caller ID in Visual Basic www.computing.net/answers/programming/caller-id-in-visual-basic/11535.html

gpib programming in visual basic www.computing.net/answers/programming/gpib-programming-in-visual-basic/2145.html

Problem In Visual Basic 6.0. www.computing.net/answers/programming/problem-in-visual-basic-60/9842.html