I'm trying to check for special characters. I tried:
QString test;
test = "Hello";
QRegExp re("[^A-Za-z0-9]");
if (!re.exactMatch(test))
{
log("False");
}
Which returns False
Also
int icount = test.count(QRegExp("[!@#$%^&()_+]"));
Which returns > 0
I don't know what am I doing wrong!
What I need is to know if a QString contains any other character than the valid: A-Z,a-z,0-9
[...]+?