Question : flutter string has capital letters
Answered by : jacob-j-van-wyk
String word = "uPPer"; // Your String
String lowerCaseTest = word.toLowerCase();
if (word == lowerCaseTest) { return false; // Not capital letter found
}
return true; // A capital letter as found in word
Source : | Last Update : Tue, 07 Feb 23
Question : check string contains any capital letters in flutter
Answered by : sourav-maurya
bool validateStructure(String value){ String pattern = r'^(?=.*?[A-Z])(?=.*?[a-z])(?=.*?[0-9])(?=.*?[!@#\$&*~]).{8,}$'; RegExp regExp = new RegExp(pattern); return regExp.hasMatch(value); }
Source : https://stackoverflow.com/questions/68226712/how-to-check-if-string-contains-both-uppercase-and-lowercase-characters | Last Update : Tue, 21 Jun 22