We're looking for best practices around including what is basically a few of the same charts in multiple applications - the case being that they're regualrly part of one business area's applications, but a subset of that application needs to be available to senior management in their app, along with other things. We can, of course, copy the load script, point to the same QVDs, etc, but then we'll be having the logic in two places that we need to maintain in parallel, which we're trying to avoid. The requiement, though, is that senior management need only use one application - sending them off to use the other app as well isn't an option.
Thanks for the reply. I'm trying to find pointers on this and am a bit confused. At first, I think you meant the new QV10 linked objects feature, but when I try that by pasting objects (which would be ideal, as I want to preserve formatting as well), I can't seem to cross documents. So, do you mean "Open QlikView File", mentioned in the help file:
This dialog is opened by selecting EditScript in the File menu or selecting the Edit Script tool and clicking the QlikView Files button in the Edit Script dialog.
The dialog lists QlikView documents (.qvw files). When a file is selected a script line is generated. When the script is executed the data will load from the .qvw file. (Only data will be loaded - no layout information is included.). Only one binary load, from a single .qvw file is possible in a script.
Or something else? Ideally, I really want to use two tables (only two of several) from one QVW in another (that has additonal data of its own). The data in the tables points to a few QVDs, and has its own rather complex load scripts - I was hoping to avoid maintaining all of that duplicatively. The apps are maintained by different developers, so it would be easy for the code to get out of sync.
What I meant by the document linking feature was having a button in qvw "A" that opened qvw "B". This is accomplished by assigning the action to an object like a button. For example, create a button. In the button properties Action pane, Add an action. Select "External" for the Action Type and "Open Qlikview Document" for the Action. This will take you a dialog where you can specify the the document name an if you want to transfer selections.
This may not be what you want, but it's good to be aware of as an option for segmenting and aggregating applications.
If you want to reuse data tables from another app, have that app script store QVDs of it's finished tables. Then you can reuse those tables in other apps without repeating the script logic.
Thanks, Rob. Just a couple more questions - thanks so much for the pointers!
1. Using a button to Open QlikView Document: Ok, I can see how this works, and just want to confirm -- if I only want the user to be able to see a couple tabs (and not the whole QVW), I'll need to enforce that with section access or something on the app that is opened, right? That is, there's no way to open just a particular tab with a button, right?
2. Having an app script store QVDs of finished tables: Do you mean a script like that mentioned in this thread ? Sorry for my ignorance, but where would that script live? Within the app, or on the server (to be triggered by Publisher)?
1. Yes, if you want to limit the view to a couple tabs, you will enforce in the opened app.
2. The script that writes the QVD could be in the same app that creates the tables you want. For example, assume you have an existing app named "Sales.qvw". It loads data from some QVDs and maybe some database tables. It implements some complex logic you don't want to repeat. It creates 8 tables and you want to resuse a couple of these (Orders and Shipments) in another app. The Sales.qvw could write it's tables out to QVDs for reuse like:
STORE Orders INTO Orders.qvd (qvd);
STORE Shipments INTO Shipments.qvd (qvd);
Many shops create qvws that do nothing but load the data and create reusable clean tables for use by the user facing applications. For more on QVDs see:
Thanks again, Rob. I think including the whole app (as a binary) is more than I want --- really, I just want the output of a couple charts within the app, including the results of any formula expressions in the chart itself (which isn't part of the load script). I guess I was looking for a way to script the equilvalent of the right-click export that you can do in QV10, ending up with the data as one would see it in the exported chart.
We'll also experiment with adding access controls on the opened app.