public static int SortLevenshteinDistance(string firstString, string secondString, Boolean ignoreCase, int numRemoveLetters) { int defaultMatch = 0; if ((firstString != null) || (secondString != null)) { //Use SortString Function to sort String and remove letters string sortFirstString = UserDefinedFunctions.SortString(firstString, " ", numRemoveLetters); string sortSecondString = UserDefinedFunctions.SortString(secondString, " ", numRemoveLetters); int cSortLevenshteinDistance = UserDefinedFunctions.LevenshteinDistance(sortFirstString, sortSecondString, ignoreCase); return(cSortLevenshteinDistance); } return(defaultMatch); }