qregexpvalidator doesn't work in Android
-
QRegExpValidator* validator = new QRegExpValidator(QRegExp("[A-a-Z-z][A-a-Z-z]\\d{0,2}\\d[0-9-A-a-Z-z][A-a-Z-z]"));
ui->lineEdit->setValidator(validator);it wokrs in windows but not in android
-
Hi,
Did you try with QRegularExpressionValidator ?
-
Hi @SGaist thanks for reply
I just try with QRegularExpressionValidator but same problem it doesn't work -
What exactly doesn't work ?
-
this work correctly in windows , but when i deploy in android it doesnt
ui->lineEdit->setMaxLength(7);
QRegularExpressionValidator* valid = new QRegularExpressionValidator(QRegularExpression("[A-a-Z-z][A-a-Z-z]\\d{0,2}\\d[0-9-A-a-Z-z][A-a-Z-z]"));
ui->lineEdit->setValidator(valid); -
Can you please describe precisely what doesn't work ? Is the input blocked ? Not validated ? etc.
-
yes the input isn't blocked , it not validated!