PDA

View Full Version : QJSEngine and error line



fober
3rd April 2015, 09:16
Hi,

I'm using the new QJSEngine and I'm trying to get the error line number (in case of error of course).
Currently I'm handling errors as documented:

if (result.isError()) result.toString().toUtf8() ...
but actually, the string is very poor: e.g. "SyntaxError: Syntax error"
I would like to get at least a line number. Contextual information would be also welcome.
Is it possible with the QJSEngine? (I'm using Qt 5.3.0)
--
Dominique