New line in text box or label

G

Guest

I'm trying to populate a label with various pieces of information inputted
into a series of text boxes. I wouyld like to have a few line breaks in the
label so that the layout is clearer. However, I don't seem to be able to do
this.

I'm now attempting to do this by populating a text box instead.

I have two questions: 1) Am I right in assuming that with a label I can't
have line breaks and:
2) In code, how do I enter a line break for the text of a text box?
 
B

Brendan Reynolds

You can use either a label or a text box. Here's an example that does both
....

Private Sub Command7_Click()

Me.Label0.Caption = Me.Text3 & vbCrLf & Me.Text5 & vbCrLf & Me.Text6
Me.Text1.Value = Me.Text3 & vbCrLf & Me.Text5 & vbCrLf & Me.Text6 &
vbCrLf

End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top