QScriptEngine evaluate
-
Hi,
i try to compare with QScriptEngine:
QString Ergebnis = engine.evaluate(" 2 < 3 ? "OK" : "BAD").toString();I get an Error
The variable OK" not existWhat should i do?
-
Hi,
i try to compare with QScriptEngine:
QString Ergebnis = engine.evaluate(" 2 < 3 ? "OK" : "BAD").toString();I get an Error
The variable OK" not existWhat should i do?
@NotYourFan You are aware that you have to escape " inside strings?
QString Ergebnis = engine.evaluate(" 2 < 3 ? \"OK\" : \"BAD\"").toString(); -
Thanks !!!