Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
String Concat and XML
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00640419
Message ID:
00641181
Views:
15
Steve,

I'll directly oppose my good friend Cetin... *s*

VFP string manipulation is as fast as the underlying C++ code that implements it.

The only time is slows down at all and where you'd want to resort to using file I/O is when strings are nearing the physical memory size. Once strings get that big you end up swapping virtual memory and preformance drops into the mud.

If you are working with strings that are up through a couple of megabytes in size you are better off just using string operations.

VFP has continually been improved, especially when you are doing string appends:
lcStr = lcStr + SomeNewStuff
VFP does not have to move strings in memory it just keeps allocating additional space for the new data.

VFP string ops are going to be at least one to two orders of magnitude faster than using the XMLDOM to build your document.

>In VB6, string concatenation is painfully slow, so to build any decent size XML document I use the DOM object to create it before I pass it.
>
>With VFP7, should I keep using the string concat or use the DOM? One thing to keep in mind is that my .exe is calling a VFP COM object, so if I use the DOM I will have an additional layer of instantiation..... If that matters.
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform