<?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: Qlikview, strange behavior with bookmarks and macros in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419571#M1225317</link>
    <description>&lt;P&gt;Yes, sure.&lt;BR /&gt;Unfortunately it is a macro that we inherited, the comments are in German which is not my language.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;LI-CODE lang="javascript"&gt;sub MOSTRATOTALI
  
	dim chart, prop, dims, pSums, str, i, j 'Variablen deklarieren  
	  
	set doc = ActiveDocument  
	set pSums  = doc.Fields("DIMENSION_TOTAL").getSelectedValues 'selektierte Werte vom Auswahlfeld in ein Array einlesen  
	  
	set chart = doc.GetSheetObject("CH53") 'Pivot auswählen  
	prop = chart.GetProperties 'Zugriff auf Eigenschaften  
	set dims = prop.Dimensions 'Auswahl der Dimensionseigenschaften  
	  
	for i = 0 to dims.Count - 1 'Pivotdimensionen durchlaufen und auslesen  
	    dims(i).ShowPartialSums = false 'für alle Dimensionen die Teilergebnisse rausnehmen  
	    for j = 0 to pSums.Count - 1 'selektierte Werte des Auswahlfeldes werden durchlaufen und ausgelsen  
	        if dims.Item(i).Title.v = pSums.Item(j).Text then dims(i).ShowPartialSums = true 'Vergleich des Auslesens + setzen des Teilergbenis  
	    next  
	    'str = str &amp;amp; dims.Item(i).Label.v &amp;amp; chr(10)  
	next  
	  
	chart.SetProperties prop 'Zuweisung der Sichtbarkeiten für die Teilergebnisse für die Dimensionseigenschaften der Pivot  
	  
	set doc = nothing 'Variablen löschen  
	set pSums = nothing  
	set chart = nothing  
	set dims = nothing  
  
end sub  &lt;/LI-CODE&gt;</description>
    <pubDate>Thu, 15 Feb 2024 14:31:37 GMT</pubDate>
    <dc:creator>castro88</dc:creator>
    <dc:date>2024-02-15T14:31:37Z</dc:date>
    <item>
      <title>Qlikview, strange behavior with bookmarks and macros</title>
      <link>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419519#M1225310</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;one of our customers has a strange problem with using bookmarks and macros on a QlikView application via AccessPoint.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I'll try to explain myself, starting with the case that works.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If I access the application with the user who is also the user of the services (I don't know if it can be useful as information) everything works. In detail: I access the sheet where there is a ListBox for choosing the dimensions and measures to represent in the table, I choose dimensions and measures and select, again via the ListBox, for which dimensions to enable the totals in the Pivot table. This last selection is managed by a macro. At this point, if I create a bookmark while the totals view is active, close and reopen the application by selecting the previously created bookmark, my pivot table presents the data with the total.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;If I log in to the application with any other user and follow the same steps, once I apply the bookmark I do not see the totals. It does this behavior with all users except the service user.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I attach some images.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Let me know if you need any other information.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="QlikAccessPoint.png" style="width: 932px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/159916i0A2C21852F262E08/image-size/large?v=v2&amp;amp;px=999" role="button" title="QlikAccessPoint.png" alt="QlikAccessPoint.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2024 14:23:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419519#M1225310</guid>
      <dc:creator>castro88</dc:creator>
      <dc:date>2024-02-15T14:23:42Z</dc:date>
    </item>
    <item>
      <title>Re: Qlikview, strange behavior with bookmarks and macros</title>
      <link>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419541#M1225311</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;
&lt;P&gt;Can I ask is the bookmark you created a document bookmark and therefore available to all users or a user bookmark available only to the user who created it?&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2024 14:12:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419541#M1225311</guid>
      <dc:creator>Brian_C</dc:creator>
      <dc:date>2024-02-15T14:12:51Z</dc:date>
    </item>
    <item>
      <title>Re: Qlikview, strange behavior with bookmarks and macros</title>
      <link>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419545#M1225312</link>
      <description>&lt;P&gt;Hi Brian,&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;each user creates his own bookmark, they are not shared.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2024 14:16:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419545#M1225312</guid>
      <dc:creator>castro88</dc:creator>
      <dc:date>2024-02-15T14:16:11Z</dc:date>
    </item>
    <item>
      <title>Re: Qlikview, strange behavior with bookmarks and macros</title>
      <link>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419550#M1225313</link>
      <description>&lt;P&gt;How does the macro contribute to the display of the totals? Do you have section access? Also, have you try with any other admin or high privilege user? Does it work? When does it not work, is for one user only or any user that is not the services account?&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2024 14:20:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419550#M1225313</guid>
      <dc:creator>igoralcantara</dc:creator>
      <dc:date>2024-02-15T14:20:35Z</dc:date>
    </item>
    <item>
      <title>Re: Qlikview, strange behavior with bookmarks and macros</title>
      <link>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419557#M1225314</link>
      <description>&lt;P&gt;Macros aren't meant to work in Ajax mode, so the only surprise here is that it's working for the service user...&lt;/P&gt;
&lt;P&gt;&lt;A href="https://support.qlik.com/articles/000045380" target="_blank"&gt;https://support.qlik.com/articles/000045380&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2024 14:23:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419557#M1225314</guid>
      <dc:creator>Or</dc:creator>
      <dc:date>2024-02-15T14:23:52Z</dc:date>
    </item>
    <item>
      <title>Re: Qlikview, strange behavior with bookmarks and macros</title>
      <link>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419560#M1225315</link>
      <description>&lt;P&gt;Yes, there is section access.&lt;BR /&gt;The problem affects all users, ADMIN and USER, it only works with the service user.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2024 14:25:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419560#M1225315</guid>
      <dc:creator>castro88</dc:creator>
      <dc:date>2024-02-15T14:25:59Z</dc:date>
    </item>
    <item>
      <title>Re: Qlikview, strange behavior with bookmarks and macros</title>
      <link>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419562#M1225316</link>
      <description>&lt;P&gt;I recommend replacing the macro with something else. Can you post the macro code for us to take a look?&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2024 14:27:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419562#M1225316</guid>
      <dc:creator>igoralcantara</dc:creator>
      <dc:date>2024-02-15T14:27:11Z</dc:date>
    </item>
    <item>
      <title>Re: Qlikview, strange behavior with bookmarks and macros</title>
      <link>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419571#M1225317</link>
      <description>&lt;P&gt;Yes, sure.&lt;BR /&gt;Unfortunately it is a macro that we inherited, the comments are in German which is not my language.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;LI-CODE lang="javascript"&gt;sub MOSTRATOTALI
  
	dim chart, prop, dims, pSums, str, i, j 'Variablen deklarieren  
	  
	set doc = ActiveDocument  
	set pSums  = doc.Fields("DIMENSION_TOTAL").getSelectedValues 'selektierte Werte vom Auswahlfeld in ein Array einlesen  
	  
	set chart = doc.GetSheetObject("CH53") 'Pivot auswählen  
	prop = chart.GetProperties 'Zugriff auf Eigenschaften  
	set dims = prop.Dimensions 'Auswahl der Dimensionseigenschaften  
	  
	for i = 0 to dims.Count - 1 'Pivotdimensionen durchlaufen und auslesen  
	    dims(i).ShowPartialSums = false 'für alle Dimensionen die Teilergebnisse rausnehmen  
	    for j = 0 to pSums.Count - 1 'selektierte Werte des Auswahlfeldes werden durchlaufen und ausgelsen  
	        if dims.Item(i).Title.v = pSums.Item(j).Text then dims(i).ShowPartialSums = true 'Vergleich des Auslesens + setzen des Teilergbenis  
	    next  
	    'str = str &amp;amp; dims.Item(i).Label.v &amp;amp; chr(10)  
	next  
	  
	chart.SetProperties prop 'Zuweisung der Sichtbarkeiten für die Teilergebnisse für die Dimensionseigenschaften der Pivot  
	  
	set doc = nothing 'Variablen löschen  
	set pSums = nothing  
	set chart = nothing  
	set dims = nothing  
  
end sub  &lt;/LI-CODE&gt;</description>
      <pubDate>Thu, 15 Feb 2024 14:31:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419571#M1225317</guid>
      <dc:creator>castro88</dc:creator>
      <dc:date>2024-02-15T14:31:37Z</dc:date>
    </item>
    <item>
      <title>Re: Qlikview, strange behavior with bookmarks and macros</title>
      <link>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419576#M1225318</link>
      <description>&lt;P&gt;Ok, let's go one step at a time. I know a little German, so here is your macro with the comments in English:&lt;BR /&gt;&lt;BR /&gt;Sub MOSTRATOTALI&lt;BR /&gt;&lt;BR /&gt;Dim chart, prop, dims, pSums, str, i, j 'Declare variables&lt;BR /&gt;&lt;BR /&gt;Set doc = ActiveDocument &lt;BR /&gt;Set pSums = doc.Fields("DIMENSION_TOTAL").getSelectedValues 'Read selected values from the selection field into an array&lt;BR /&gt;&lt;BR /&gt;Set chart = doc.GetSheetObject("CH53") 'Select the pivot table&lt;BR /&gt;prop = chart.GetProperties 'Access properties&lt;BR /&gt;Set dims = prop.Dimensions 'Select dimension properties&lt;BR /&gt;&lt;BR /&gt;For i = 0 To dims.Count - 1 'Loop through pivot dimensions and read them&lt;BR /&gt;dims(i).ShowPartialSums = False 'Remove partial sums for all dimensions&lt;BR /&gt;For j = 0 To pSums.Count - 1 'Loop through selected values from the selection field and read them&lt;BR /&gt;If dims.Item(i).Title.v = pSums.Item(j).Text Then dims(i).ShowPartialSums = True 'Compare read + set partial result&lt;BR /&gt;Next&lt;BR /&gt;Next&lt;BR /&gt;&lt;BR /&gt;chart.SetProperties prop 'Assignment of visibilities for partial results for the dimension properties of the pivot&lt;BR /&gt;&lt;BR /&gt;Set doc = Nothing 'Delete variables&lt;BR /&gt;Set pSums = Nothing&lt;BR /&gt;Set chart = Nothing&lt;BR /&gt;Set dims = Nothing&lt;BR /&gt;&lt;BR /&gt;End Sub&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Second a few ideas to do the same without using a macro:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;1. Use Variables and Button States: Create variables that represent the selected values in your selection field. Then use these variables in the expressions of your pivot table to filter the data. You can use buttons to allow the user to select values and update the variables accordingly.&lt;/P&gt;
&lt;P&gt;2. Use Conditional Selections in QlikView: You can use conditional expressions in the properties of your pivot table to control the display of subtotals based on the selected values in your "DIMENSION_TOTAL" field.&lt;/P&gt;
&lt;P&gt;These approaches can help you achieve the same result without needing to use macros.&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2024 14:40:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419576#M1225318</guid>
      <dc:creator>igoralcantara</dc:creator>
      <dc:date>2024-02-15T14:40:33Z</dc:date>
    </item>
    <item>
      <title>Re: Qlikview, strange behavior with bookmarks and macros</title>
      <link>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419583#M1225319</link>
      <description>&lt;P&gt;&lt;A href="https://community.qlik.com/t5/Official-Support-Articles/Considerations-When-Using-Macros-In-QlikView/ta-p/1710861" target="_blank"&gt;https://community.qlik.com/t5/Official-Support-Articles/Considerations-When-Using-Macros-In-QlikView/ta-p/1710861&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2024 14:55:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419583#M1225319</guid>
      <dc:creator>David_Friend</dc:creator>
      <dc:date>2024-02-15T14:55:02Z</dc:date>
    </item>
    <item>
      <title>Re: Qlikview, strange behavior with bookmarks and macros</title>
      <link>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419605#M1225320</link>
      <description>&lt;P&gt;Thank you.&lt;BR /&gt;I only have one doubt on the second point, I don't see any settings for conditional expressions in partial sums in the graph tab. Am I understanding wrong?&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2024 15:21:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2419605#M1225320</guid>
      <dc:creator>castro88</dc:creator>
      <dc:date>2024-02-15T15:21:08Z</dc:date>
    </item>
    <item>
      <title>Re: Qlikview, strange behavior with bookmarks and macros</title>
      <link>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2420276#M1225329</link>
      <description>&lt;P&gt;Cascading actions triggered by events are executed by the server at different levels.&lt;/P&gt;
&lt;P&gt;If the user make a selection in the field "ShowTotals", the macro runs on level 1.&lt;/P&gt;
&lt;P&gt;A bookmark is nothing more than an event that triggers actions. The selection triggered by the bookmark in the field "ShowTotals" is executed at level 1, the macro triggered by this selection now is executed at level 2.&lt;/P&gt;
&lt;P&gt;But this is not allowed per default! On Ajax client a user can only run actions on level 1, no higher levels. The service user has no limits!&lt;/P&gt;
&lt;P&gt;To get it work for all users you have to increase the MaxActionLevel on the Server:&lt;/P&gt;
&lt;P&gt;Stop the server service.&lt;/P&gt;
&lt;P&gt;Open the file:&lt;/P&gt;
&lt;P&gt;c:\ProgramData\QlikTech\QlikViewServer\Settings.ini&lt;/P&gt;
&lt;P&gt;Add the line&lt;/P&gt;
&lt;P&gt;MaxActionLevel=2&lt;/P&gt;
&lt;P&gt;to section [Settings 7].&lt;/P&gt;
&lt;P&gt;Start the server service.&lt;/P&gt;
&lt;P&gt;Now it should works for all users.&lt;/P&gt;</description>
      <pubDate>Fri, 16 Feb 2024 23:10:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qlikview-strange-behavior-with-bookmarks-and-macros/m-p/2420276#M1225329</guid>
      <dc:creator>cwolf</dc:creator>
      <dc:date>2024-02-16T23:10:02Z</dc:date>
    </item>
  </channel>
</rss>

