Home All Groups Group Topic Archive Search About

VbCr, VbCrLf, VbLf, VbNewLine etc Not Working

Author
23 Mar 2006 10:57 AM
Burning_Ranger
If I do something like:
txtAddress.Text = "test1" & vbCrLf & "test2

All I get is:
test1[][]test2

The [] represents a character that looks like a rectangle.

Why is this?

I have another project file I did as part of a tutorial and that works
fine, but my main prog doesn't. It's the same if I use Chr(10), Chr(13)
etc. I've also tried concatenating the text into a string variable and
displaying that in the text box but no effect.

Author
23 Mar 2006 11:04 AM
guy
have you set the Multiline property of the text box?

Show quoteHide quote
"Burning_Ranger" wrote:

> If I do something like:
> txtAddress.Text = "test1" & vbCrLf & "test2
>
> All I get is:
> test1[][]test2
>
> The [] represents a character that looks like a rectangle.
>
> Why is this?
>
> I have another project file I did as part of a tutorial and that works
> fine, but my main prog doesn't. It's the same if I use Chr(10), Chr(13)
> etc. I've also tried concatenating the text into a string variable and
> displaying that in the text box but no effect.
>
>
Author
23 Mar 2006 11:06 AM
Larry Lard
Burning_Ranger wrote:
> If I do something like:
> txtAddress.Text = "test1" & vbCrLf & "test2
>
> All I get is:
> test1[][]test2
>
> The [] represents a character that looks like a rectangle.
>
> Why is this?

Your TextBox needs to have MultiLine = True in order to display more
than one line.

--
Larry Lard
Replies to group please