I am trying to split a string according to delimiter the equevelant code in C# is :
char[] delimiterChars = { ' ', ',', '.', ':', '\t' };
String[] query = sometext.Split(delimiterChars);
but I want to do it in Qt
I am trying to split a string according to delimiter the equevelant code in C# is :
char[] delimiterChars = { ' ', ',', '.', ':', '\t' };
String[] query = sometext.Split(delimiterChars);
but I want to do it in Qt
Use split function that accepts Qt Regular Expression.
QRegExp rx("(\\ |\\,|\\.|\\:|\\t)"); //RegEx for ' ' or ',' or '.' or ':' or '\t'
QStringList query = sometext.split(rx);