|
-
October 29th, 1998, 03:04 PM
#1
I really am a newbie ;(
Hey guys and gals... just wondering if you know how I can make a newline when printing data. I know in C/C++ it's ENDL or "\n", but how do I do this with Visual Basic?
Thanks 
-
October 29th, 1998, 04:01 PM
#2
Re: I really am a newbie ;(
Hi,
dim EndOfLine as string
EndOfLine = chr(13) & chr(10) ' = \n
'if you want to print something like
'Hello\nWorld
debug.print "Hello" & EndOfLine & "World"
bye
__Neph__
-
October 29th, 1998, 04:19 PM
#3
Re: I really am a newbie ;(
Thanx, except that has problems in VB5... I figured it out myself just a few min ago... you gotta use the built in VB control vbcrlf
peace
-
November 10th, 1998, 07:41 PM
#4
Re: I really am a newbie ;(
hey Alex use these...
Constant Equivalent Description
vbCrLf Chr(13) + Chr(10) Carriage return–linefeed combination
vbCr Chr(13) Carriage return character
vbLf Chr(10) Linefeed character
vbNewLine Chr(13) + Chr(10) or Chr(13) Platform-specific new line character; whichever is appropriate for current platform
vbNullChar Chr(0) Character having value 0
vbNullString String having value 0 Not the same as a zero-length string (""); used for calling external procedures
vbTab Chr(9) Tab character
vbBack Chr(8) Backspace character
vbFormFeed Chr(12) Not useful in Microsoft Windows
vbVerticalTab Chr(11) Not useful in Microsoft Windows
so put in a vbCrLf instead of chr(13) + chr(10)... VB will replace the constant at runtime (compile-time) but it makes the code MUCH more readable !
phil 
ps check out the 'constants' section under help... it will open your eyes to a lot of things you can do in VB
-
November 10th, 1998, 07:41 PM
#5
Re: I really am a newbie ;(
hey Alex use these...
Constant Equivalent Description
vbCrLf Chr(13) + Chr(10) Carriage return–linefeed combination
vbCr Chr(13) Carriage return character
vbLf Chr(10) Linefeed character
vbNewLine Chr(13) + Chr(10) or Chr(13) Platform-specific new line character; whichever is appropriate for current platform
vbNullChar Chr(0) Character having value 0
vbNullString String having value 0 Not the same as a zero-length string (""); used for calling external procedures
vbTab Chr(9) Tab character
vbBack Chr(8) Backspace character
vbFormFeed Chr(12) Not useful in Microsoft Windows
vbVerticalTab Chr(11) Not useful in Microsoft Windows
so put in a vbCrLf instead of chr(13) + chr(10)... VB will replace the constant at runtime (compile-time) but it makes the code MUCH more readable !
phil 
ps check out the 'constants' section under help... it will open your eyes to a lot of things you can do in VB
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|