Use String.Compare to Compare Case-insensitive Strings

To perform a case-insensitive string comparison, use the String.Compare function. One of this function’s overloaded methods has a third paramenter (boolean) which specifies whether a case should be ignored or not.

    "Srinath" == "srinath"                            //returns false    System.String.Compare( "Srinath", "srinath", true ) //returns true

Share the Post:
Share on facebook
Share on twitter
Share on linkedin


Recent Articles: