Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to start a new line in a msgBox 1

Status
Not open for further replies.

ossse

Programmer
Jun 26, 2007
49
US
I'm sure this is a very simple question, but I have NO experience with message boxes.

I am displaying a message box, and would like to put a space between two lines of the message. I am told to display either (chr (13)) or (chr(10)), but I am not sure how I am suppose to display this.

Here is my code

Code:
Dim strMsg1 As String, seqBegin As Integer, strMsg2 As String

strMsg1 = "Do you want the sequence number to begin at 1?"(chr(13))"(Click 'No' if you want to begin the sequence number at a different number)"

seqBegin = MsgBox(strMsg1, vbYesNo)

Thanks, in advance
 
Sorry, I just figured it out... here is how it is done:

Code:
strMsg1 = "Do you want the sequence number to begin at 1?" & (Chr(13)) & (Chr(13)) & "(Click 'No' if you want to begin the sequence number at a different number)"

BUT ... I have another question.

I would like to display a message box that prompts the user to enter a number. Is this done in a message box? Can anyone give me a point in the right direction on how to do this.
 

vbCrLF = Chr(13) & Chr(10) New line

Take a look at InputBox
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top