<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Error when running macro via accesspoint in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Error-when-running-macro-via-accesspoint/m-p/364587#M1276716</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do you have Excel installed on the QlikView Server?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 31 Aug 2012 20:07:40 GMT</pubDate>
    <dc:creator />
    <dc:date>2012-08-31T20:07:40Z</dc:date>
    <item>
      <title>Error when running macro via accesspoint</title>
      <link>https://community.qlik.com/t5/QlikView/Error-when-running-macro-via-accesspoint/m-p/364586#M1276715</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;DIV&gt; Hi all,&lt;/DIV&gt;&lt;DIV&gt;What am I doing wrong? Is there a way to actually run this macro?&lt;/DIV&gt;&lt;DIV&gt;I've attached a screen shot of the error I get.&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;I have done this on the QMC - &lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #636363; font-family: &amp;amp;quot;Arial&amp;amp;quot;,&amp;amp;quot;sans-serif&amp;amp;quot;; font-size: 9pt; mso-fareast-font-family: &amp;amp;quot;Times New Roman&amp;amp;quot;"&gt;"1. Make sure you are granting System Access to your macros in the server through QEMC (System, Setup, QlikView Servers, expand and click, Seucrity tab in the right pane "Allow unsafe macro execution on server" and "Allow macro execution on server" ticked) and in the Macro editor, (Ctrl + M, bottom left drop downs)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style=": ; mso-list: Ignore; color: #636363; font-size: 9pt; sans-serif&amp;amp;quot: ; font-family: &amp;amp;quot; Arial&amp;amp;quot: ; ,&amp;amp;quot: ; mso-fareast-font-family: Arial;"&gt;2.&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #636363; font-family: &amp;amp;quot;Arial&amp;amp;quot;,&amp;amp;quot;sans-serif&amp;amp;quot;; font-size: 9pt; mso-fareast-font-family: &amp;amp;quot;Times New Roman&amp;amp;quot;"&gt;If you are creating some filesystem object (such an excel file) make sure you are using the IE Plugin."&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;This is my macro:&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 8pt;"&gt;&lt;DIV&gt;Sub ExcelAddComment&lt;BR /&gt; VarHolder1 = 0&lt;BR /&gt; set val=ActiveDocument.Fields("RecID").GetPossibleValues&lt;BR /&gt; for i=0 to val.Count-1&lt;BR /&gt; VarHolder1 = VarHolder1 + 1&lt;BR /&gt; next&lt;BR /&gt; &lt;BR /&gt; if VarHolder1 &amp;gt; 1 then&lt;BR /&gt; msgbox ("More than one record is showing.&amp;nbsp; Refine your selection to select only one index.")&lt;BR /&gt; exit sub&lt;BR /&gt; else&lt;BR /&gt; end if&lt;BR /&gt; &lt;BR /&gt; Set oXL=CreateObject("Excel.Application")&lt;BR /&gt; &lt;BR /&gt; set doc = ActiveDocument&lt;BR /&gt; set mySelection = doc.fields("RecID").GetSelectedValues&lt;BR /&gt; for i = 0 to mySelection.Count -1&lt;BR /&gt; strIndex = mySelection.Item(i).text&lt;BR /&gt; next&lt;BR /&gt; &lt;BR /&gt; set vCommentsToExcel = ActiveDocument.Variables("vName")&lt;BR /&gt; VarHolder1 = vCommentsToExcel.GetContent.String&lt;BR /&gt; &lt;BR /&gt; set vCommentsToExcel = ActiveDocument.Variables("vGrade")&lt;BR /&gt; VarHolder2 = vCommentsToExcel.GetContent.String&lt;BR /&gt; &lt;BR /&gt; set vCommentsToExcel = ActiveDocument.Variables("vStartDate")&lt;BR /&gt; VarHolder3 = vCommentsToExcel.GetContent.String&lt;BR /&gt; &lt;BR /&gt; set vCommentsToExcel = ActiveDocument.Variables("vEndDate")&lt;BR /&gt; VarHolder4 = vCommentsToExcel.GetContent.String&lt;BR /&gt; &lt;BR /&gt; set temp = ActiveDocument.GetApplication.GetProperties&lt;BR /&gt; VarHolder5 = mid(temp.UserName,4)&lt;BR /&gt; &lt;BR /&gt; f_name ="\\\Live QV\Excel Loads\Comments.xls"&lt;BR /&gt; &lt;BR /&gt; set oWB = oXL.Workbooks.Open(f_name)&lt;BR /&gt; set oSH = oWB.Worksheets.Item(1)&lt;BR /&gt; &lt;BR /&gt; With oWB.Worksheets.Item(1).Range("a1:a50")&lt;BR /&gt; Set c = .Find(strIndex, , , 2, 1, 2, 0)&lt;BR /&gt; If Not c Is Nothing Then&lt;BR /&gt; firstAddress = c.Address&lt;BR /&gt; Do&lt;BR /&gt; VarHolder = VarHolder + 1&lt;BR /&gt; Set c = .FindNext(c)&lt;BR /&gt; Loop While Not c Is Nothing And c.Address &amp;lt;&amp;gt; firstAddress&lt;BR /&gt; End If&lt;BR /&gt; End With&lt;BR /&gt; &lt;BR /&gt; if VarHolder = 1 then&lt;BR /&gt; msgbox("There already is a record for this item. If you want to change the note, delete it first.")&lt;BR /&gt; oWB.Close&lt;BR /&gt; set oSH = Nothing&lt;BR /&gt; set oWB = nothing&lt;BR /&gt; set oXL = nothing&lt;BR /&gt; set v = ActiveDocument.Variables("vName")&lt;BR /&gt; v.SetContent&amp;nbsp; "",true&lt;BR /&gt; exit sub&lt;BR /&gt; else&lt;BR /&gt; &lt;BR /&gt; oSH.Range("A65536").End(-4162).Offset(1,0).FormulaR1C1 = strIndex&lt;BR /&gt; oSH.Range("A65536").End(-4162).Offset(0,1).FormulaR1C1 = VarHolder1 'name&lt;BR /&gt; oSH.Range("A65536").End(-4162).Offset(0,2).FormulaR1C1 = VarHolder2 'grade&lt;BR /&gt; oSH.Range("A65536").End(-4162).Offset(0,3).FormulaR1C1 = VarHolder3 'start&lt;BR /&gt; oSH.Range("A65536").End(-4162).Offset(0,4).FormulaR1C1 = VarHolder4 'enddate&lt;BR /&gt; oSH.Range("A65536").End(-4162).Offset(0,5).FormulaR1C1 = VarHolder5 'ccode&lt;BR /&gt; &lt;BR /&gt; If f_name="False" then&lt;BR /&gt; &lt;BR /&gt; Set oXL=nothing&lt;BR /&gt; Exit sub&lt;BR /&gt; End If&lt;BR /&gt; &lt;BR /&gt; oWB.Save&lt;BR /&gt; oWB.Close&lt;BR /&gt; Set oSH=nothing&lt;BR /&gt; Set oWB=nothing&lt;BR /&gt; Set oXL=nothing&lt;BR /&gt; set v = ActiveDocument.Variables("vName")&lt;BR /&gt; v.SetContent&amp;nbsp; "",true&lt;BR /&gt; msgbox("Record added")&lt;BR /&gt; ActiveDocument.Reload&lt;BR /&gt; ActiveDocument.ClearAll&lt;BR /&gt; end if&lt;BR /&gt; End Sub &lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;SPAN style="font-size: 8pt;"&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;Any help would be much appreciated!&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 26 Jan 2026 18:19:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Error-when-running-macro-via-accesspoint/m-p/364586#M1276715</guid>
      <dc:creator />
      <dc:date>2026-01-26T18:19:17Z</dc:date>
    </item>
    <item>
      <title>Re: Error when running macro via accesspoint</title>
      <link>https://community.qlik.com/t5/QlikView/Error-when-running-macro-via-accesspoint/m-p/364587#M1276716</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do you have Excel installed on the QlikView Server?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 31 Aug 2012 20:07:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Error-when-running-macro-via-accesspoint/m-p/364587#M1276716</guid>
      <dc:creator />
      <dc:date>2012-08-31T20:07:40Z</dc:date>
    </item>
    <item>
      <title>Re: Error when running macro via accesspoint</title>
      <link>https://community.qlik.com/t5/QlikView/Error-when-running-macro-via-accesspoint/m-p/364588#M1276717</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Excel doesn't need to be installed on the server.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do Shift+Ctrl+M and see how the macro security is set. It must be set to system access.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 31 Aug 2012 20:14:18 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Error-when-running-macro-via-accesspoint/m-p/364588#M1276717</guid>
      <dc:creator>m_woolf</dc:creator>
      <dc:date>2012-08-31T20:14:18Z</dc:date>
    </item>
  </channel>
</rss>

