Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
In the following image (taken from Qlik Help), let's call:
From the JavaScript code in my Qlik Sense extension, I am able to retrieve the app ID using:
require( ["js/qlik"], function ( qlik ) {
console.log(qlik.currApp().id);
});
Is there a similar way to get more information about the app, for instance, the app name? (="Tutorial")
You can access the app name from the App layout on the qTitle property
Here is a example: Access App Name - JSFiddle
You can access the app name from the App layout on the qTitle property
Here is a example: Access App Name - JSFiddle
Thanks for the example Alexander, I have accepted your answer.
Here's my simplified version:
// Get app name and id
require( ["js/qlik"], function ( qlik ) {
qlik.currApp().getAppLayout().then(applayout => {
var appName = applayout.layout.qTitle;
var appId = applayout.layout.qFileName;
console.log(appName + " : " + appId);
});
});