how to call nanoflow from custom JavaScript action in Mendix

0
Hi please help me with syntax of calling nanoflow from my custom javascript action      mx.data.callNanoflow({            nanoflow: testNanoflow, // parameter JS-action            context: testEntity, // parameter JS-action            origin: page, // ??????            callback: function(result) {                alert("Nanoflow completed with result " + result);            },            error: function(error) {                alert(error.message);            }       });     I have found above code but what is context and origin values should be?
asked
1 answers
2

For origin, always use this.mxform. Don’t worry too much about what this is, this will work. I believe it is just letting the nanoflow know that any page activity involved is connected to the form / page the nanoflow runs from.

 

For context add the input parameter of the nanoflow, which is typically a Mendix object itself. It should be of type ‘Mendix/lib/MxContext’ like all Mendix objects which you interact with via the Client API

answered