22 June, 2009
0 Comments
0 categories
If you want to compare two string, ignoring case, use string.Compare and not string.ToLower, for performance reasons.
if (string.Compare(stringA, stringA, true) == 0)
{
// Strings are equal (case ignored)
}
Tags: C#