Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
Join this live chat April 6, 10AM EST - QlikView to Qlik Sense REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Publisher Macro Failure

Hi,

I have several straight charts that have total fields - I have a macro that will read and sum the totals from each chart upon a variable change.  This works fine locally, but not when the document is published.  The macro is below - the document macro security is set to allow system access - I have other macros that are running fine.  Are any of the actions in the macro restricted by the publisher?  Are users unable to write to variables?

Thanks in advance.

Sub get_total_2

sheetObj=Array("CH08","CH17","CH12")

for i=0 to UBound(sheetObj)

set obj= ActiveDocument.GetSheetObject(sheetObj(i))

  rowCount = obj.GetRowCount-1

  colCount = obj.GetColumnCount-1

  cellVar = cellVar + CDbl(ActiveDocument.GetSheetObject(sheetObj(i)).GetCell(rowCount,colCount).text)

next

  ActiveDocument.Variables("vVarTotal").SetContent cellVar, True

End Sub

2 Replies
ashfaq_haseeb

Hi,

Not all Macros are supported on server.

Go Through the below blog post to have better idea

http://community.qlik.com/blogs/qlikviewdesignblog/2014/04/28/macros-are-bad

Regards

ASHFAQ

offjunior
Creator
Creator

Hello!

For a macro to work completely in the QV server, you must deploy applications using IE Plugin together with the Web Browser Internet Explorer. Also, it must be given all the rights to run macros, both QV Server as the application where the Macro