Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR DART

check if string is number dart

//From coflutter.com

bool isNumericUsingRegularExpression(String string) {
  final numericRegex = 
    RegExp(r'^-?(([0-9]*)|(([0-9]*).([0-9]*)))$');

  return numericRegex.hasMatch(string);
}
Source by coflutter.com #
 
PREVIOUS NEXT
Tagged: #check #string #number #dart
ADD COMMENT
Topic
Name
5+1 =