<?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: Activation of Bookmark within a macro in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605990#M1117855</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this is how you activate a bookmark in macro:&lt;/P&gt;&lt;P&gt;ActiveDocument.RecallDocBookmark "MyBookmark"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this helps and this is what you need.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;MT&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 19 Feb 2014 12:00:04 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-02-19T12:00:04Z</dc:date>
    <item>
      <title>Activation of Bookmark within a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605989#M1117854</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;I want to activate a bookmark within a macro and then after the Bookmark has been activated it should export all of my selected object to excel without clearing the bookmark.&lt;/P&gt;&lt;P&gt;My macro works for exporting the objects but it never selects the bookmark.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to create reports with each bookmark created. So for example; I need to activate the first bookmark, and then export data to two different sheets. After this has been done I need to clear the bookmark that were selected, select the next bookmark and export data to the next two sheets in the same excel report.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it makes sense and something like this is possible.&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Stevie&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Feb 2014 11:55:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605989#M1117854</guid>
      <dc:creator>stevietm</dc:creator>
      <dc:date>2014-02-19T11:55:10Z</dc:date>
    </item>
    <item>
      <title>Re: Activation of Bookmark within a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605990#M1117855</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this is how you activate a bookmark in macro:&lt;/P&gt;&lt;P&gt;ActiveDocument.RecallDocBookmark "MyBookmark"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this helps and this is what you need.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;MT&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Feb 2014 12:00:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605990#M1117855</guid>
      <dc:creator />
      <dc:date>2014-02-19T12:00:04Z</dc:date>
    </item>
    <item>
      <title>Re: Activation of Bookmark within a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605991#M1117856</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Magdalena,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please see below a part of&amp;nbsp; my script where I am using the above suggested.&lt;/P&gt;&lt;P&gt;Would you please be so kind just to have a look at the scrips and tell me where i am going wrong.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sub exportToExcel_Variant3 &lt;/P&gt;&lt;P&gt;ActiveDocument.RecallDocBookmark "Sumari - AI Oral Levofloxacin"&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Dim aryExport(1,3) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;aryExport(0,0) = "Price_File_TB01"&lt;/P&gt;&lt;P&gt;aryExport(0,1) = "Sales Overview"&lt;/P&gt;&lt;P&gt;aryExport(0,2) = "A1"&lt;/P&gt;&lt;P&gt;aryExport(0,3) = "data"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;aryExport(1,0) = "LB182"&lt;/P&gt;&lt;P&gt;aryExport(1,1) = "Top Customers"&lt;/P&gt;&lt;P&gt;aryExport(1,2) = "A1"&lt;/P&gt;&lt;P&gt;aryExport(1,3) = "data"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ActiveDocument.UnlockAll&lt;/P&gt;&lt;P&gt;ActiveDocument.ClearAll true&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Dim objExcelWorkbook 'as Excel.Workbook&lt;/P&gt;&lt;P&gt;Set objExcelWorkbook = copyObjectsToExcelSheet(ActiveDocument, aryExport)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;'// Now either just leave Excel open or do some other stuff here&lt;/P&gt;&lt;P&gt;'// like saving the excel, some formatting stuff, ...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;end sub&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Stevie&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Feb 2014 12:07:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605991#M1117856</guid>
      <dc:creator>stevietm</dc:creator>
      <dc:date>2014-02-19T12:07:31Z</dc:date>
    </item>
    <item>
      <title>Re: Activation of Bookmark within a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605992#M1117857</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is the Bookmarkname spelled right?? Is it a DocumentBookmark?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;MT&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Feb 2014 12:11:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605992#M1117857</guid>
      <dc:creator />
      <dc:date>2014-02-19T12:11:37Z</dc:date>
    </item>
    <item>
      <title>Re: Activation of Bookmark within a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605993#M1117858</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;try only to select the bookmark with your macro?? if that doesnt work then please chech you security restrictions on the left side of the macro editor.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Feb 2014 12:14:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605993#M1117858</guid>
      <dc:creator />
      <dc:date>2014-02-19T12:14:01Z</dc:date>
    </item>
    <item>
      <title>Re: Activation of Bookmark within a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605994#M1117859</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Magdalena,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The bookmark is spelled correct also it is a document bookmark. And see screen shot of security restrictions. I have tried system access as well as safe mode.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="" class="jiveImage" src="https://community.qlik.com/legacyfs/online/53477_pastedImage_1.png" style="max-width: 1200px; max-height: 900px;" /&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Stevie&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Feb 2014 12:30:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605994#M1117859</guid>
      <dc:creator>stevietm</dc:creator>
      <dc:date>2014-02-19T12:30:59Z</dc:date>
    </item>
    <item>
      <title>Re: Activation of Bookmark within a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605995#M1117860</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you are having problems with selecting the bookmark, I would suggest debugging with just using that code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;sub Test&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;ActiveDocument.RecallDocBookmark "Sumari - AI Oral Levofloxacin"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;end sub&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 10pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 10pt; line-height: 1.5em;"&gt;Then see if it actually selects this bookmark. Other than that, the code looks fine to me.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 10pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 10pt; line-height: 1.5em;"&gt;EDIT: That Clear Selections might be causing problem, you probably want to execute that last.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Hope this helps!&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Feb 2014 15:14:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605995#M1117860</guid>
      <dc:creator>jerem1234</dc:creator>
      <dc:date>2014-02-19T15:14:06Z</dc:date>
    </item>
    <item>
      <title>Re: Activation of Bookmark within a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605996#M1117861</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jerem,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I Finally got it to select the bookmark and export that data. The problem was the clear selection that you mentioned as it were in the wrong position.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But now i have a new problem, Now i need the macro to clear the selections and select a new bookmark and export that data to the same document but to different sheets. Please have a look at my script below. The scrips works for the first export and selects the first bookmark but it does not go on to export data to sheet 2, 3 or 4 also it does not clear the selection made by the first bookmark.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;sub exportToExcel_Variant3 &lt;BR /&gt; &lt;BR /&gt; Dim aryExport(3,3)&lt;BR /&gt; &lt;BR /&gt; ActiveDocument.RecallDocBookmark "Sumari - AI Oral Market"&amp;nbsp; 'Select Bookmark&lt;BR /&gt; &lt;BR /&gt; aryExport(0,0) = "Obj1"&lt;BR /&gt; aryExport(0,1) = "Sales Overview"&lt;BR /&gt; aryExport(0,2) = "A1"&lt;BR /&gt; aryExport(0,3) = "data"&lt;BR /&gt; &lt;BR /&gt; aryExport(1,0) = "Obj2"&lt;BR /&gt; aryExport(1,1) = "Top Customers"&lt;BR /&gt; aryExport(1,2) = "A1"&lt;BR /&gt; aryExport(1,3) = "data"&lt;BR /&gt; &lt;BR /&gt; Set objExcelWorkbook = copyObjectsToExcelSheet(ActiveDocument, aryExport)&lt;BR /&gt; &lt;BR /&gt; ActiveDocument.ClearAll true&lt;BR /&gt; &lt;BR /&gt; ActiveDocument.RecallDocBookmark "Sumari - AI Oral Levofloxacin"&amp;nbsp; 'Select Bookmark&lt;BR /&gt; &lt;BR /&gt; aryExport(2,0) = "Obj3"&lt;BR /&gt; aryExport(2,1) = "Sales Overview2"&lt;BR /&gt; aryExport(2,2) = "A1"&lt;BR /&gt; aryExport(2,3) = "data"&lt;BR /&gt; &lt;BR /&gt; aryExport(3,0) = "Obj4"&lt;BR /&gt; aryExport(3,1) = "Top Customers2"&lt;BR /&gt; aryExport(3,2) = "A1"&lt;BR /&gt; aryExport(3,3) = "data"&lt;BR /&gt; &lt;BR /&gt; Dim objExcelWorkbook 'as Excel.Workbook&lt;BR /&gt; Set objExcelWorkbook = copyObjectsToExcelSheet(ActiveDocument, aryExport)&lt;BR /&gt; &lt;BR /&gt; ActiveDocument.ClearAll true&lt;BR /&gt; &lt;BR /&gt; objExcelWorkbook.Worksheets ("Sales Overview").Rows("2:3").Delete = True&lt;BR /&gt; end sub &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind Regards&lt;/P&gt;&lt;P&gt;Stevie&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Feb 2014 06:33:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605996#M1117861</guid>
      <dc:creator>stevietm</dc:creator>
      <dc:date>2014-02-20T06:33:21Z</dc:date>
    </item>
    <item>
      <title>Re: Activation of Bookmark within a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605997#M1117862</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are you going to the another sheets - like: objExSheet2.Activate? How looks the routine for &lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;copyObjectsToExcelSheet"&lt;/SPAN&gt;? Take also a look on &lt;A href="/t5/forums/searchpage/tab/message?q=macro export&amp;amp;type=document"&gt;http://community.qlik.com/search.jspa?q=macro+export&amp;amp;type=document&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Feb 2014 08:33:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605997#M1117862</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2014-02-20T08:33:14Z</dc:date>
    </item>
    <item>
      <title>Re: Re: Activation of Bookmark within a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605998#M1117863</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #575757; font-family: arial, helvetica, sans-serif;"&gt;I am pretty sure your problem lies with how your function, &lt;SPAN style="font-size: 12px;"&gt;copyObjectsToExcelSheet&lt;/SPAN&gt;, works (I searched Qlikcommunity and found which one this was). For the second set of objects, I would create a new array, &lt;/SPAN&gt;&lt;SPAN style="color: #575757; font-size: 12.222222328186035px; font-family: arial, helvetica, sans-serif;"&gt;Dim aryExport&lt;STRONG&gt;2&lt;/STRONG&gt;(1,3), and change the first array to only hold 2 objects,&amp;nbsp; a&lt;SPAN style="font-size: 12px;"&gt;ryExport&lt;/SPAN&gt;(1,3).&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #575757; font-size: 12.222222328186035px; font-family: arial, helvetica, sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #575757; font-size: 12.222222328186035px; font-family: arial, helvetica, sans-serif;"&gt;If you change this, it should create two excel documents.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #575757; font-size: 12.222222328186035px; font-family: arial, helvetica, sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #575757; font-size: 12.222222328186035px; font-family: arial, helvetica, sans-serif;"&gt;Im guessing by sheets, you mean sheets in excel? If you only want one excel document with four sheets, you'll have to take out the part of creating the excel file in the function &lt;SPAN style="font-size: 12px;"&gt;copyObjectsToExcelSheet and put it inside your method &lt;SPAN style="font-size: 12px;"&gt;exportToExcel_Variant3. This way it doesnt create an excel document&amp;nbsp; every time the function is called (you'll also have to add this as parameters to your function and pass the necessary objects).&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #575757; font-size: 12px; font-family: arial, helvetica, sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-size: 12px; font-family: 'Courier New';"&gt;&lt;SPAN style="color: #575757; font-family: arial, helvetica, sans-serif;"&gt;Hope this helps!&lt;/SPAN&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Feb 2014 14:45:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Activation-of-Bookmark-within-a-macro/m-p/605998#M1117863</guid>
      <dc:creator>jerem1234</dc:creator>
      <dc:date>2014-02-20T14:45:08Z</dc:date>
    </item>
  </channel>
</rss>

