How many characters can a CString object conatin?
Printable View
How many characters can a CString object conatin?
As many as you like... Until you run out of memory...
As many numbers as a long variable can hold.
2^32.
Wayne
I seem to remember seeing somewhere that a CString couldn't hold more than 32767 characters, but I have just tried adding 65536 and it was OK. Has anyone else seen this 'limit'? Perhaps it is a throw-back to 16-bit VC++, where the parameter to GetBuffer() was an int (therefore, a maximum of 32767).