Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
String vs. StringBuilder
Message
From
30/05/2003 11:02:10
 
 
To
30/05/2003 09:33:32
General information
Forum:
ASP.NET
Category:
Other
Miscellaneous
Thread ID:
00794481
Message ID:
00794520
Views:
15
Hi, Bill.

>Since all of the data is concatenated into the single string in one statement, does the rule to use a StringBuilder for multiple operations apply in this case?

Let me throw my guessing here (someone may jump in and tell something else):

The problem with string manipulation on VB6 ages was that "dynamic memory reallocation" was a killer machine. You know, the process in a loop of going to the memory, taking the variable, concatenating the string, and then putting it in the memory again...

That's when the StringBuilder comes for the rescue.

So, in my understanding of your sample, as you're throwing all the concatenated string at once to the memory, it doesn't seem that you're gonna benefit from using the StringBuilder.

Can someone tell if this is right or wrong?? :)
Claudio Lassala
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform