CString , std::string Size Limitation

I'm having trouble with populating CString and std::string with really large strings.  Roughly, after 200 chars, CString and std::string start to poop out and throw exceptions.

How does one deal with large strings...I really need to have a large string with over 500-1000 characters.

I'm really desperate and need to fix this as soon as possible..please help!!

I'm using Visual Studio C++ 6.0 -- I have to use this compiler, there's no choice.
lcorAsked:
Who is Participating?
 
AxterCommented:
Both CString and std::string can handle far more then 200 chars.
More then likely, you're getting some type of heap corruption.

Please post your code.
0
 
robear7ntCommented:
I have had no problems with large strings using CStrings. Is it throwing OUT_OF_MEMORY exceptions?
Can you please show us a sniplet of your code that is having problems, so we better understand what is happening?
0
 
AlexNekCommented:
I haven't such a problem with CString too. I only want to notice speed problem with 10000 symbols string when you add a symbols dynamically at the string. Then you need to allocate enough space before. It is possible that the problem in an other part of your code.
0
 
lcorAuthor Commented:
I can't post the entire code -- propietary stuff...so, let me investigate further the heap issue.  I know at least that CString should be okay and something else is happenning.  Thanks!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.