Using the qw-sys-info component

Introduction

You can retrieve system meta-information to support the development process of widgets or you can add system meta information to custom visualizatons using the qw-sys-info component. The following system metadata information can be retrieved:

  • All apps.
  • Sheets and objects in the current app.
  • Visualizations in the current app.
  • Dimensions and measures in the current app.
  • All visualization extensions available.
  • All widgets available.
  • All bookmarks available.
  • All current selections.
  • All master objects.

Limitation

Widgets containing a qw-sys-info component cannot be exported to image or to PDF from a sheet in Qlik Sense.

Properties

 

Name Type Description
content Strings

Returns a comma-separated list of desired objects.

These can be:

  • apps
  • sheets
  • fields
  • measures
  • dimensions
  • extensions
  • bookmarks
  • currentselections
  • masterobjects
  • visualizations

If no content is defined (left empty) all object types are returned except visualizations.

Note: The type visualizations is the slowest content type to be returned because detailed information for all visualizations in the app are retrieved from the Qlik associative engine.

Examples

Getting a list of sheets

This example shows how to retrieve the titles of all the sheets in an app. In this example, the Helpdesk Management app is used.

Use sheet.qMeta.title to retrieve the titles of the sheets.

<qw-sys-info content="sheets">
	<ul style="margin-left:20px;">
		<li ng-repeat="sheet in sheets"
			ng-bind="sheet.qMeta.title" />
	</ul>
</qw-sys-info>
Output when the Helpdesk Management app is selected

Getting a list of dimensions and measures

This example shows how to retrieve the titles of all dimensions and measures in an app. In this example, the Helpdesk Management example app is used.

Use dimension.qMeta.title and measure.qMeta.title to retrieve the dimension titles and the measure titles.

<qw-sys-info content="dimensions,measures">
	<b>Dimensions:</b><br>
	<ul style="margin-left:20px;">
		<li ng-repeat="dimension in dimensions" ng-bind="dimension.qMeta.title">
	</li></ul>
	<b>Measures:</b><br>
	<ul style="margin-left:20px;">
		<li ng-repeat="measure in measures" ng-bind="measure.qMeta.title">
	</li></ul>
</qw-sys-info>
Output when the Helpdesk Management app is selected

Retrieving visualization and bookmark information using a filter

This example shows how to retrieve and filter information about visualizations and bookmarks. In this example, the Helpdesk Management app is used.

Initially, information about all visualizations containing the string Cases is retrieved.

<qw-sys-info content="visualizations">
	<div ng-repeat="vis in visualizations | filter: 'Cases'">
        <pre ng-bind="vis | json" />
        <hr/>
    </div>
</qw-sys-info>
Output when the Helpdesk Management app is selected

Then the HTML is changed to retrieve information about all bookmarks in the app containing the string Cases.

<h2>My Bookmarks:</h2>
<br>
<qw-sys-info content="bookmarks">
	<div ng-repeat="bookmark in bookmarks | filter: 'Cases'">
        <b>Title:</b> {{bookmark.qData.title}}<br>
        <b>Description:</b> {{bookmark.qData.description}}<br>
        <hr>
    </div>
</qw-sys-info>
Redefined output when the Helpdesk Management app is selected