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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Lenght of a String

Status
Not open for further replies.

Dan688

Programmer
Dec 29, 2003
128
0
0
GB
What is the max. length a string can be in VB6?

Cheers,
 
From help:

String
10 bytes + string length
0 to approximately 2 billion



Two strings walk into a bar. The first string says to the bartender: 'Bartender, I'll have a beer. u.5n$x5t?*&4ru!2[sACC~ErJ'. The second string says: 'Pardon my friend, he isn't NULL terminated'.
 
If you are trying to display a long string in a textbox, then your string is limited to 65535 charachters so you will have to use a RichTextBox instead.

LF

"As far as the laws of mathematics refer to reality, they are not certain; as far as they are certain, they do not refer to reality."--Albert Einstein
 
If you create long strings, try not to do anything to them. String concatenation & splitting is very expensive in VB6.

Chip H.


____________________________________________________________________
Click here to learn Ways to help with Tsunami Relief
If you want to get the best response to a question, please read FAQ222-2244 first
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top