This article aims to document how to create a customized CSS file to disable individual items in the Ajax toolbar, for example, More or Add Object.
In this approach to hide individual items in the Ajax toolbar we create a custom CSS file (the first step) and then call this custom file in a copy of the opendoc.htm (the second step).
Content:
Creating customized files
- Create a custom .css file to hide, for example, the More menu. In the file, add the following
.ctx-menu-action-FOLDOUTDOWN
{
display: none !important;
}
- Create a copy of opendoc.htm located in C:\Program Files\QlikView\Server\QlikViewClients\QlikViewAjax
Do not alter the original opendoc.htm!
- Rename the copy and edit it, adding a reference to the custom .css created.
In this example, our custom.css file is located in the /htc folder.
<link rel="stylesheet" type="text/css" media="screen" href="/QvAjaxZfc/htc/default.css" />
<link rel="stylesheet" type="text/css" media="screen" href="/QvAjaxZfc/htc/custom.css" />
<link rel="apple-touch-icon" href="/QvAjaxZfc/htc/Images/Touch/touch-icon.png" />
Changes in QlikView Server to use the new opendoc.htm file
- Open the QlikView Management Console
- Navigate to System > Setup > QlikView Web Servers
- Open your QlikView WebServer
- Open the AccessPoint tab
- In the Accesspoint Settings section, change the Client Paths for Full Browser and Small Devices to the path and name of your opendoc.htm copy, such as opendoc_new.htm:
/QvAjaxZfc/opendoc_new.htm
From here on, the customized opendoc_new.htm will be used when opening any document in the Ajax client, and the customized CSS will be applied.
If you want to apply the custom behavior only to specific documents:
- Open the QlikView Management Console
- Navigate to Documents > User Documents
- Choose your document
- Open the Server tab
- In the Availability section, check Full Browser and Small Device Version and set the Url to
/QvAjaxZfc/opendoc_new.htm
Available toolbar items
These are the available toolbar items:
- ctx-menu-action-CLEARSTATE
- ctx-menu-action-BCK
- ctx-menu-action-FWD
- ctx-menu-action-UNDO
- ctx-menu-action-REDO
- ctx-menu-action-LS (lock all selections)
- ctx-menu-action-US (unlock all selections)
- ctx-menu-action-CS (current selections)
- ctx-menu-action-TOGGLENOTES
- ctx-menu-action-REPOSITORY
- ctx-menu-action-NEWSHEETOBJ
- ctx-menu-action-SHOWFIELDS
- ctx-menu-action-ADDBM
- ctx-menu-action-REMBM
- ctx-menu-action-BookMarks
- ctx-menu-action-Reports
- ctx-menu-action-FOLDOUTDOWN
- .ctx-menu-action-SENDBACKTOACCESSPOINT
The information in this article is provided as-is and will be used at your discretion. Depending on the tool(s) used, customization(s), and/or other factors, ongoing support on the solution below may not be provided by Qlik Support.
Environment
QlikView
Related Content
How to remove the toolbar from QlikView AccessPoint