As a suggestion, you also can use the QChar::digitValue()
to obtain the numeric value of the digit. For example:
for (int var = 0; var < myString.length(); ++var) {
bool ok;
if (myString.at(var).isDigit()){
int digit = myString.at(var).digitValue();
//DO SOMETHING HERE WITH THE DIGIT
}
}