Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Macro not working on Access Point

I'm trying to open a QVW when the user clicks on a tab, I tried using the "OnActivateSheet" trigger and adding a External -> Open URL action but it did not work. What I did instead was add a External -> "Run macro" action and created a macro like so:

SUB pressButton

  Set Button1 = ActiveDocument.GetSheetObject("BU01")

  Button1.Press

end sub

In this case when the user clicks the tab, this triggers the "pressButton" function which basically "clicks" the button which has the action of "Open URL". This works fine opening the QVW with Qlikview desktop, but when I tried to test the functionality through the access point, the macro/function does not work, but if I click the button the "Open URL" action works fine. Do you have any ideas why this is not working? or maybe you could help to a find a new approach.

Thanks.

7 Replies
tresesco
MVP
MVP

Several things are to be checked:

Which client?  Macros don't work in Ajax in general

Security settings are set properly in the server ?

Please check :

Macros not working in Server

https://community.qlik.com/message/809662#809662

gautik92
Specialist III
Specialist III

if you r using ajax macros doesnot work

Have a look at this

Macros are Bad

jonathandienst
Partner - Champion III
Partner - Champion III

Many triggers do not fire when the document is viewed from Access point and OnOpen is one of them. See the links in the previous posts for more information.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Not applicable
Author

Security settings have been set properly to allow macros to run, it seems that I won't be able to make this work through the access point though, have you ever come across an implementation like this? maybe you can give me an idea to take a new approach

jerrysvensson
Partner - Specialist II
Partner - Specialist II

OnActivateSheet is one of the actions that doesn't work in Ajax. See reference manual for the.

tresesco
MVP
MVP

Instead of tabs, you could use text boxes that would appear as tab and use conditional enablement of the objects in the dashboard. Check Prescription Tracker.qvw that appears in the start page of your qv desktop. That way you actually get a click on text box to fire a trigger to open your qvw.

Not applicable
Author

Actually it´s wrong that Macros don´t work in AJAX-Client in general. We only use AJAX-Client and use a lot of Macros with it. Just not every type of Macro work. But for example, "ServerSideExport" or the requested "Button-Press-Fuctionality" works just fine.

You can´t do "WScript/CScript"-operations, but you can manipulate QlikView-Objects. Show/Hide Dimensions, Show all Dimension in a Pivot-Table, Export Data from a Table, Dynamic-Update etc..

I encountered the same problem as "Miguel Rivas" with the Press-Button-Functionality. Fist i thought it wouldn´t work in AJAX-Client, because it didn´t open the URL (Document-Chaining). Then i tried to put a second Action on the button (Set Variable Value) and this Action was triggered by the Macro. I don´t know why, but it just doesn´t work with the "Open URL"-Action, all others ,which i tried so far, did work. It seems like "Button1.Press" is not interepreted as a real "Click", its something different and can´t trigger everything. Maybe Qlik can fix this (QV 11 SR 12)