Does a string have a length limit?

Does a string have a length limit?

Post by cyberdud » Mon, 20 Oct 2008 16:31:39


Hi,

I have some very long strings to be held in some string variables.
May I ask if the string variables have limits in their lengths?
Thanks.

Mike
 
 
 

Does a string have a length limit?

Post by Helmut Web » Mon, 20 Oct 2008 18:47:58

Hi Mike,

from the online help:

String Data Type


There are two kinds of strings: variable-length and fixed-length
strings.

A variable-length string can contain up to approximately 2 billion
(2^31) characters.


A fixed-length string can contain 1 to approximately 64K (2^16)
characters.

Greetings from Bavaria, Germany

Helmut Weber, MVP WordVBA

Vista Small Business, Office XP