Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi, I'm trying to embed qlick sense object in hybrid app using below code.
var config = {
host: window.url,
isSecure: true
};
require(["js/qlik"], function(qlik) {
// open the app
var app = qlik.openApp("61af269d-5b22-4d8c-afa5-8dda1624c577", config);
// insert Qlik objects into the page.
app.getObject(document.getElementById("qlikContent"), "objectID");
});
But I'm getting "Cannot read property 'openApp' of undefined" error:
error:
VM1637 qlikReport.js:22 Uncaught TypeError: Cannot read property 'openApp' of undefined at VM1637 qlikReport.js:22
Can anyone please let me know what i'm missing here.
Thanks.
I am having this issue as well. Were you able to fix it?
Hi,
Have you got qlike requirejs (which inludes a lot more than requirejs) included?? Do you configure requirejs baseUrl? You probably need to have the prefix set in your config, just a slash if you do not use virtual prox.
Erik Wetterberg
Theres 2 kinds of requirejs??? Where do i get the one for qlik?
I don't understand what the prefix is... I thought it was just what comes after the port number in a uri?
Hi,
In your mashup you need to include a file called require.js that includes not only the requirejs library, but also some other libraries and qlik modules you need. Normally this is made in the html file, something like this:
<script src="../../resources/assets/external/requirejs/require.js"></script>
The prefix in this context is the virtual proxy that is part of the URL. If you do not use a virtual proxy (like for example in desktop) you would set it to slash.
Erik Wetterberg
that src points to a location on the local machine. I need the correct require.js file (with qlik stuff inside) to put in that local folder.
You could also modify this link to point to your Sense installation. There is also a link to the css file you need to change.
Erik Wetterberg