Is there any method in qt class which validate a string content for hexadecimal or not?
I've made some custom methods to validate the string is a hexadecimal or not. But, couldn't find anything in Qt to do that or maybe I've overlooked.
Is there any method from Qt class to do this operation?
You could use "toLongLong":http://doc.qt.nokia.com/4.7/qstring.html#toLongLong or similar routines. However, this will allow you to check only part of the string. You may to iterate.
@ QString str = "FF";
qint64 hex = str.toLongLong(&ok, 16); @
Is there in the doc. As you see, the base is 16. returns 0 on failure or the hex number.
well, I thought like "isxdigit()" similar function would be there .