Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP vs C# String handling
Message
From
23/05/2011 07:56:33
 
 
To
23/05/2011 07:42:59
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Miscellaneous
Thread ID:
01511379
Message ID:
01511471
Views:
68
>My point was that in C# since there is no way to do a case insensitive search you have to do in effect three searches (yes, I realize there would be other possible combinations of upper and lower but these are in fact the three most likely )

There is actually. But you'll need to write a method that uses String.IndexOf() in a loop http://msdn.microsoft.com/en-us/library/ms224424.aspx
You can pass an offset where the search starts in the string and StringComparison


>You were saying that in VFP the case insensitive search would take longer than the case sensitive search which is true. But to get the same outcome, one needs to do as I did in C# - search three times ( sensitively ). So, while each pass may be faster than the one insensitive pass, the cumulative time is still greater. No?
Gregory
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform