Ignore the case while comparing two strings in C#
This blog will describe how to ignore the case while comparing two strings in c#
Below is the best way to compare the string in C# and ignore the case sensitive.
string strCompare = "testcomPARE";
if (strCompare.Equals("testcompare", StringComparison.InvariantCultureIgnoreCase))
{
///
} |