English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

In a text box ,I enabled Multi line
I want to add data to text box but in sevral lines

like :
text1.text= text1.text & .... & "visual basic"

Hi
visual basic

NOT

Hi visual basic

in the place of ... , I think there is something adding ,some sort of command to tell VB to enter this but in new line

2007-12-30 16:36:53 · 3 answers · asked by Anonymous in Computers & Internet Programming & Design

3 answers

You need to add carriage return (vbcrlf).

Ex:

text1.text = "Hi" & vbcrlf & "visual basic"

2007-12-30 16:47:08 · answer #1 · answered by bails52000 2 · 0 0

Are you going to be displaying this on a webpage? If not, then just concatenate the strings with vbcrlf

String1 & vbcrlf & String2

If you are going to be displaying this on a webpage then you want to make sure that it can be read as HTML when it comes from the database. It would be as follows:

"

" & String1 & "

" & String2 & "

"

I hope this helps,

Jim F

2007-12-31 00:49:57 · answer #2 · answered by Jim F 2 · 0 0

Try experimenting with control characters, in particular carriage return (CR) and line feed (LF), chr$(10) and chr$(13) or perhaps vice versa. In many apps those characters will advance a line.

2007-12-31 01:02:29 · answer #3 · answered by VirtualSound 5 · 0 0

fedest.com, questions and answers