0 Replies Latest reply: Sep 20, 2017 8:46 AM by Max Mustermann RSS

    Engine API - applyPatches not working

    Max Mustermann

      Dear community members!

      I am new to Qlik Sense and try to implement a small extension in Qlik Sense Desktop. The task of this extension is to change the title of an object (e.g. test-Image field) when a button is clicked.

       

      The relevant code in my .js file looks like this:

       

       

      var msg_applyPatches_textfield = {

             "handle": 2,

             "method": "ApplyPatches",

             "params": {

              "qPatches": [

               {

                "qPath": "/title",

                "qOp": "replace",

                "qValue": "\"Test THREE\""

               }

              ],

              "qSoftPatch": false

             }

      }

       

      ws.send(JSON.stringify(msg_applyPatches_textfield));

       

      The JSON code from msg_applyPatches_textfield works fine in the Engine API Explorer but when I use this code in Qlik Sense Desktop i receive the following response in the DevConsole:

       

      DevConsole_Screenshot.PNG

      Strangely, the id is always 0 whereat it increments in the Engine API Explorer.

       

      Exactly the same happens when I try to use the setProperties operation.

       

      Thank you all