Button - AJAX/Webview

Buttons can be used in QlikView to perform commands or actions, e.g. export data to files, launch other applications or execute macros.

By right-clicking the object, the Object Menu will be displayed.

Button: Object Menu

The object menu can be opened as a context menu by right-clicking on a sheet object, or by clicking the icon in the object caption (if shown).

The commands in the menu may vary depending on whether WebView is used from inside QlikView or opening the document in a web browser. The menu contains the following commands:

Properties...

Opens the Properties dialog for the active sheet object.

Notes

Allows creating and sharing notes about the current object.

See: Notes and Comments

Copy

Copies the selected sheet object(s) to the clipboard. This function only copies sheet objects, not data or images.

Delete

Removes the selected object from the sheet.

Button Properties

The Properties dialog is opened by selecting Properties from the Object menu. If the Properties command is dimmed, you probably do not have the privileges necessary to perform property changes.

Button Text Enter the text the button should display. The value may be entered as a calculated formula. Click to open the Edit Expression dialog.
Actions To add an action click . The Action Settings popup for the new action opens instantly. It is also possible to select an action in the drop-down and to click to edit. The icon moves the items in the list. The icon removes the items from the list.

Actions Settings Popup

Type
Choose a Type in the drop-down list.
Subtype
Choose a Subtype in the drop-down list. The subtypes available depend on the Action Type chosen.

Action Types and Actions

Selection

Select in Field

Selects the values and fields that are specified. In the Search String you can specify a search mask, e.g. (A|B) will select both A and B.

Select Excluded

Selects the excluded values in the specified field.

Select Possible

Selects the possible values in the specified field.

Toggle Select

Toggles between the current selection and the specified Field and Search String. In the Search String you can specify a search mask, e.g. (A|B) will select both A and B.

Forward

Goes one step forward in the list of selections.

Back

Goes back one step in the list of selections.

Pareto Select

Makes a pareto selection in the specified field based on an expression and percentage. This type of selection is used to select the top contributors to a measure, typically in line of a general 80/20 rule. For example, to find the top customers that contribute to 80% of the turnover, Customer should be used as field, sum(Turnover) should be used as expression and 80 should be used as percentage.

Lock Field

Locks the selections in the specified field.

Lock All

Locks all values in all fields.

Unlock Field

Unlocks the selections in the specified field.

Unlock All

Unlocks all values in all fields.

Unlock and Clear All

Unlocks all values and clears all selections in all fields.

Clear Other Fields

Clears all related fields except the one specified.

Clear All

Clears all selections except locked ones.

Clear Field

Clears a specific field.

Layout

Activate Object

Activates the object specified by Object ID. This function does not work in Ajax client.

Activate Sheet

Activates the sheet specified by Sheet ID.

Activate Next Sheet

Opens the next sheet in the document.

Activate Previous Sheet

Opens the previous sheet in the document.

Minimize Object

Minimizes the object specified by Object ID.

Maximize Object

Maximizes the object specified by Object ID.

Restore Object

Restores the object specified by Object ID.

Bookmark

Apply Bookmark

Applies a bookmark specified by Bookmark ID. If two bookmarks have the same ID, the document bookmark is applied. To apply the server bookmark specify Server\bookmarkID. 

Create Bookmark

Creates a bookmark from the current selection. Specify Bookmark ID and Bookmark Name. Select Hidden to create a hidden bookmark.

Replace Bookmark

Replaces the bookmark specified by Bookmark ID with the current selection.

Print

Print Object

Prints the object specified by Object ID. Specify the Printer name if the object should be sent to another printer than the default printer. (Not available as document and sheet trigger.)

Print Sheet

Prints the sheet specified by Sheet ID. (Not available as document and sheet trigger.) This function does not work in AJAX client.

Print Report

Prints the report specified by Report ID. Specify the Printer name if the report should be sent to another printer than the default printer. Mark the check box Show Print Dialog if you want the Windows print dialog to be shown. (Not available as document and sheet trigger.)

External

Some clients may not handle this setting!

 

Export

Exports a table containing a specific set of fields, but only those records that are applicable according to the made selection are exported. Click on the Setup button on the Actions page to open the Export Action Settings dialog. (not available as document and sheet trigger)

Launch

Launches an external program. The following settings can be configured in the Actions dialog:
Application
Click on Browse... to find the application that should be launched. (Not available as document and sheet trigger.)
Filename
Enter the path to the file that should be opened with the application specified above. (Not available as document and sheet trigger.)
Parameters
Specify parameters for the command line from which the application is started. (Not available as document and sheet trigger.)
Working Directory
Sets the working directory for the application to be launched. (Not available as document and sheet trigger.)
Exit application when QlikView is closed
Forces the application to be closed when QlikView is exited. (Not available as document and sheet trigger.)
This function does not work in AJAX client.

Open URL

Opens the URL in the default web browser. (Not available as document and sheet trigger.)

Open QlikView Document

Opens the specified document. The file extension must be included. (Not available as document and sheet trigger.)
Mark the check box Transfer State to transfer the selections from the original document to the one you wish to open. The opened document will first be cleared of selections.
Mark Apply state on top of current to retain the second document’s selections and apply the original document’s selections on top of them.

Note: Use Apply state on top of current with caution, as it can cause unpredictable results if the two documents selections are conflicting. In most cases it should be sufficient with using the Transfer State option.

Open in same Window opens the new document in the same browser tab when using the AJAX ZFC client.

Note: Open QlikView Document action is not supported for non domain users when using the Internet Explorer plugin

Run Macro

Enter the path and name of the macro to be run. Type any name for which it is possible to later create a macro in the Edit Module dialog, or a calculated expression for dynamic update.

Set Variable

Assigns a value to the specified variable.

Show Information

Shows the associated information, such as a text file or an image for the field specified by Field. This function does not work in AJAX client.

Close This Document

Closes the active QlikView document.

Reload

Performs a reload on the current document. This function does not work both in AJAX client and IE-plugin.

Dynamic Update

Performs a dynamic update of the data in the currently loaded document. The statement for the dynamic update is to be entered in the Statement field.

The intended usage of Dynamic Update allows a QlikView Administrator to feed limited amounts of data in to a QlikView document from a single source without running a reload of the document. Analysis can then be performed by multiple clients connecting to the QlikView Server.

Note! The uploaded information is stored in RAM only so any data added or updated using Dynamic Update will be lost if a reload of the document is performed.

The following grammar describes the possible statements and their components that can be used with the Dynamic Update feature:

  • statements ::= statement { “;” statement }
  • statement ::= insert_statement | update_statement | delete_statement | begin_transaction_statement | commit_transaction_statement
  • insert_statement ::= "INSERT" "INTO" ("*" | table_name) field_list "VALUES" value_list {"," value_list} ["KEY" ["AUTO" | (" (" field_list ")")] ["REPLACE" (["WITH" "ONE"] | "EACH") ]]
  • update_statement ::= "UPDATE" ("*" | table_name) set_clause {"," | set_clause} "WHERE" condition ["AUTO" "INSERT"]
  • delete_statement ::= "DELETE" "FROM" ("*" | table_name] "WHERE" condition
  • begin_transaction_statement ::= "BEGIN" ("TRANSACTION" | "TRAN") [trans_name]
  • commit_transaction_statement ::= "COMMIT" ["TRANSACTION" | "TRAN"] [trans_name]
  • table_name ::= identifier | quoted_name
  • field_list ::= "(" field_name {"," field_name} ")"
  • value_list ::= "("value {"," value} ")"
  • set_clause ::= "SET" field_name "=" any_valid_non_aggregated_qlikview_expression
  • field_name ::= identifier | quoted string
  • value ::= identifier | any_qlikview_number | quoted string
  • condition ::= any_valid_non_aggregated_qlikview_expression
  • identifier ::= any_qlikview_identifier
  • quoted_string ::= "[" [^]]+ "]"

Example:  

UPDATE AbcTable SET Discount = 123 WHERE AbcField=1

Note: To use this feature, Dynamic Update must be allowed both on the Document and on the Server.
Enable Condition Enter an expression that will determine the status of the button. If the expression returns 0, the button will be disabled, if the expression returns 1, the button will be enabled. If no expression is entered, 1 is assumed. Buttons that are disabled due to underlying status cannot be enabled by means of a condition. The value may be entered as a calculated formula. Click to open the Edit Expression dialog.

Button Properties: Presentation

Presentation

Background Style Aqua
Default for new buttons. Gives a rounded button with three dimensional glassy look. Click to set a color.
Plain
Produces a traditional plain QlikView button. Click to set a color.
System Default
Provides a solid background in the color defined for buttons in the operating system.

Single Image
Uses an image for the button. Click to browse for an image.

Combined Image
Produces an image button with three parts, one for each possible state (active, inactive or depressed). Click to browse for an image. The image file must consist of three images of the button side by side, the first of the active button, the second of a depressed button and the third of a dimmed (inactive) button.
Transparency Sets the level of transparency of the object background by entering a value or by dragging the slider. At 100% the background will be completely transparent.
Text Align Left, Centered or Right alignment of the button text.
More.../Less...

Styles

Text on Button To set the text color click . To set the font type click .
Caption Font

To set the caption font type click .

Active Caption To to set the background color for the active caption click . To set the text color click .
Inactive Caption To to set the background color for the inactive caption click . To set the text color click .
Use Border Mark this check box in order to use a border around the sheet object. Click to set the color of the border.
Border Width Specify the width of the border in the input field, or drag the slider to the desired width. The width is specified in pixels.
Rounded Corners Click to open the Rounded Corners popup.
Note:

Rounded Corners is only available if you have selected Advanced Styling Mode in Document Properties: General.

Button Properties: Caption

Caption

Label In the text box you can enter a title to be shown in the caption of the sheet object. If no Label is set, the name of the field will be used if Show Caption is selected. The value may be entered as a calculated formula. Click to open the Edit Expression dialog.
Show Caption When this option has been checked a caption will be drawn at the top of the sheet object. List boxes and other "box objects" will have the option switched on by default whereas buttons, text objects and line/arrow objects will not.
Caption Alignment Left/Centered/Right
Multi Line Caption (Word Wrap) If this option is checked, the text will be displayed in two or more rows.
Number of Rows If multiple lines are allowed for the caption, specify the number of rows in the input field, or drag the slider to the desired number.
Caption Alignment Top/Centered/Bottom
More.../Less...

Icons in Caption

Some options may not be available for all objects.

Menu

Opens the object menu.

Clear

Clears all the current selections in the active sheet object.

Print

Opens the selected sheet object(s) in tabular format in another browser window. Some clients may not handle this setting!

Copy Data

Copies the field values in the sheet object. Some clients may not handle this setting!

Copy Image to Clipboard

Copies the sheet object as an image to the Clipboard. Some clients may not handle this setting!

Send to Excel

Exports possible (including selected) values to Microsoft Excel, which is automatically launched if not already running. The exported values will appear as one column in a new Excel worksheet. For this functionality to work Microsoft Excel 2007 or later must be installed on the computer. Some clients may not handle this setting!

Allow Minimize

When this option has been checked a minimize icon will be displayed in the window caption of the sheet object, providing that it is possible to minimize the object. Furthermore, this will make it possible to minimize the object by double-clicking the caption.

Auto Minimize

This option becomes available when Allow Minimize is checked. When Auto Minimize is checked for several sheet objects on the same sheet, all but one will be automatically minimized at any time. This is useful e.g. for alternately displaying several graphs in the same sheet area.

Allow Maximize

When this option has been checked a maximize icon will be displayed in the window caption of the sheet object, providing that it is possible to maximize the object. Furthermore, this will make it possible to maximizing the object by double-clicking the caption. If both Allow Minimize and Allow Maximize are checked, double-clicking will effect minimizing of the object.

Help Text

Here you may enter a help text to be displayed in a pop-up window. This option is not available at document level. The value may be entered as a calculated formula. Click to open the Edit Expression dialog.
It is possible to enter e.g. a description of the sheet object. A help icon will be added to the window caption of the object. When the mouse pointer is over the icon, the text will be displayed in a pop-up window.

Fast Type Change

Here you can enable toggling between chart types. Not available for all objects. Click to open the popup.

Fast Type Settings Popup

Check the boxes for the chart types you want to toggle between using fast type change.

Button Properties: Options

Options

Some options may not be available for all objects.

Read Only Makes the chart read only, that is selections cannot be made by clicking or painting with the mouse in the chart.
Allow Move/Size If this option has been deselected it will be impossible to move or resize the sheet object.
Allow Copy/Clone If this option has been deselected it will be impossible to make a copy of the sheet object. This setting may not be handled by all clients.
Size Object to Data Normally the borders around all table sheet objects in QlikView will shrink when selections cause the size of the table to be less than allocated size for the sheet object. By deselecting this check box this automatic adjustment of size will be turned off leaving any surplus space blank.
Allow Show Info in Caption When the Info function is in use an info icon will be displayed in the window caption whenever a field value has information associated to it. If you don't want the info icon to be displayed in the caption, you can uncheck this option. Only available for list box, statistics box, multi box and input box.
Preserve Scroll Position When marking this check box and the corresponding one in the User Preferences, Objects dialog, QlikView will preserve the vertical scroll position when a selection in table objects has been made.
Use Show Condition The sheet object will be shown or hidden depending on a conditional expression which will be evaluated continuously depending on e.g. selections etc. The sheet object will only be visible when the condition returns true. The value may be entered as a calculated formula. Click to open the Edit Expression dialog.
Normal Specify the position of the object by setting Left and Top margins, and Width and Height of the object.
Minimized Specify the position of the minimized sheet object by setting Left and Top margins, and Width and Height of the minimized object.
More.../Less...

Options

Owner Domain and User Id of the owner.
Share Object Enable to share objects with other users. Enabling this selection will enable the settings below.
Share with Choose either Share with everyone or Share by username.
Users (Domain\UserID) If Share by username is chosen a list with added users will be shown. To add users click , a row is added, highlight the row to unlock it and edit the user information. To remove users click after each user to be removed.

 

Did this information help you?

Thanks for letting us know. Is there anything you'd like to tell us about this topic?

Can you tell us why it did not help you and how we can improve it?