QJSEngine throw engine exception in c++ native method



  • I am looking for a way to throw a QJSEngine exception within my native c++ function while we evaluate a script.

    In QScriptEngine I used:

    return context->throwError( QScriptContext::SyntaxError, "Argument not valid.");
    

    How can I achieve this in the QJSEngine?


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.