How can I use QStrings inside a QtScript? For instance:
QString script = " QString a = "abcd"; a.contains("cd"); "
QScriptEngine e;
QScriptValue res = e.evaluate( script );
Or is it only possible to use java code?
I`m making a program where the user can search for music by tags, and I want to make the users be able to script this. For instance
ARTIST.contains(" lady ") || ARTIST.contains( "gaga" ) && YEAR>2009; (stupid examle, but you get the idea)
I was thinking to first replace ARTIST (and other tags) by the a qstring with the tag value and then evaluate the script.
Any ideas how to do this?
Bookmarks