> > From me:
> >I think you'll find that StrCompare() and StrNCompare() are slower in the
> >4.0 SDK.
>
> From Ken Krugler:
> StrCompare should be roughly comparable in speed, less the trap
> dispatch overhead of calling through to TxtCompare.
>
> StrNCompare will be slower in 4.0 - the longer the strings you're
> passing in, the bigger the performance issue.
>
> > From me:
> >If you are certain your app is running only on single-byte char sets with
> >7-bit ASCII, then you could speed things up even more by using
> >StrCompareAscii() and StrNCompareAscii() instead.
>
> From Ken Krugler:
> The Str[N]CompareAscii routine should only be used if the text you're
> sorting is never displayed to the user - in that case you could use
> it on any text (regardless of the character encoding), since it's
> just doing a raw byte-by-byte comparison.
>
> Otherwise, you want to use locale-specific sorting as provided by the
> Txt[Caseless]Compare routine.
>
Thanks, Ken, for correcting my answer to Kevin's question. I knew you'd do
a better job with this than I did. :) That's why I added the caveat, "Ken
Krugler could probably tell you more about this whenever he is on the list."
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/