<?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 How to toggle Relative property in Chart (Straight table) in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345110#M574708</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I would like to use macro to toggle Relative property of my Chart (Straight table), no success so far. The code I used is the following and it does not work. How to refer to the Qlikview objects and properties? Are there any good tutorial or book available? The Qlikview's documentation for macro is bad. I cannot find any so far. I attended Qlikview developer training, the Macro is not covered. Thanks in advance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;sub test777&lt;BR /&gt;set chart = ActiveDocument.GetSheetObject("CH11")&lt;BR /&gt;set cp = chart.GetProperties&lt;BR /&gt;cp.Relative = false&lt;BR /&gt;chart.setProperties cp&lt;BR /&gt;end sub &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 08 Jun 2012 16:16:06 GMT</pubDate>
    <dc:creator />
    <dc:date>2012-06-08T16:16:06Z</dc:date>
    <item>
      <title>How to toggle Relative property in Chart (Straight table)</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345110#M574708</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I would like to use macro to toggle Relative property of my Chart (Straight table), no success so far. The code I used is the following and it does not work. How to refer to the Qlikview objects and properties? Are there any good tutorial or book available? The Qlikview's documentation for macro is bad. I cannot find any so far. I attended Qlikview developer training, the Macro is not covered. Thanks in advance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;sub test777&lt;BR /&gt;set chart = ActiveDocument.GetSheetObject("CH11")&lt;BR /&gt;set cp = chart.GetProperties&lt;BR /&gt;cp.Relative = false&lt;BR /&gt;chart.setProperties cp&lt;BR /&gt;end sub &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 08 Jun 2012 16:16:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345110#M574708</guid>
      <dc:creator />
      <dc:date>2012-06-08T16:16:06Z</dc:date>
    </item>
    <item>
      <title>How to toggle Relative property in Chart (Straight table)</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345111#M574709</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The relative option is bound to a specific expression, so you need to specify the expression. If you want to change relative option for the first expression, use&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;p.Expressions.Item(0).Item(0).Data.ExpressionData.Relative = false&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;instead of your line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You're right that there is not much documentation about the macro programming and QV automation interface and OCX API. I assume you know the qvw and pdf covering the macro and API (download available on download site)?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Stefan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 08 Jun 2012 16:48:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345111#M574709</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2012-06-08T16:48:04Z</dc:date>
    </item>
    <item>
      <title>How to toggle Relative property in Chart (Straight table)</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345112#M574710</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; Thank you for your quick response. This is my first post and I got what I need. I really appreciate your timely help. By the way, could you please give me some explanation about the code. I would like to know the logic in order to be used in other applications. Thanks again!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 08 Jun 2012 17:37:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345112#M574710</guid>
      <dc:creator />
      <dc:date>2012-06-08T17:37:51Z</dc:date>
    </item>
    <item>
      <title>How to toggle Relative property in Chart (Straight table)</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345113#M574711</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Since you are new to Qlikview, I'd like to point out that what you are trying to do with a macro is a bad practice for an application that runs on the server. The Ref Guide (QV11 sec 82.2) warns against using SetProperties on the server, and I have seen performance and stability problems from it's use. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are two better alternatives I can suggest to get the same behavior:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. Any QV version. Use grouped expresssions. Define the expression twice, once with relative and once without. Group them together using the Group button and let the user switch bewtween.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. QV11. Again, define the expression twice and use the conditional enablement feature to toggle one or the other on.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 08 Jun 2012 18:59:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345113#M574711</guid>
      <dc:creator>rwunderlich</dc:creator>
      <dc:date>2012-06-08T18:59:34Z</dc:date>
    </item>
    <item>
      <title>Re: How to toggle Relative property in Chart (Straight table)</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345114#M574712</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you, Bob. We are using QV11 now. Could you please give me instruction how to implement this feature by using conditional enablement? I know Macro can do a lot of things and do you have guideline for how to make best of use of macro? &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 08 Jun 2012 19:57:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345114#M574712</guid>
      <dc:creator />
      <dc:date>2012-06-08T19:57:38Z</dc:date>
    </item>
    <item>
      <title>Re: How to toggle Relative property in Chart (Straight table)</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345115#M574713</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The conditional enablement is set by checking the "Conditional" box next to en expression (on the Expression tab) and then entering a condition to be tested. If the condiion evaluates to true, that expression is enabled. The condition expression depends on what you are trying to achieve. For example, you may have a button that sets a variable named "vShowRelative". Your expression would then test that variable.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tha attached example shows three approaches to switching between absolute or relative. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. Using two expressions grouped. &lt;/P&gt;&lt;P&gt;2. Using two expressoions, conditionally enabled by the variable vShowRelative -- which is toggled by pressing the button. &lt;/P&gt;&lt;P&gt;3. A single expression that uses an if() function to produce either the absolute or relative output. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Have fun. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 08 Jun 2012 21:57:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345115#M574713</guid>
      <dc:creator>rwunderlich</dc:creator>
      <dc:date>2012-06-08T21:57:03Z</dc:date>
    </item>
    <item>
      <title>Re: How to toggle Relative property in Chart (Straight table)</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345116#M574714</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Wunderbar &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Aug 2014 10:24:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345116#M574714</guid>
      <dc:creator />
      <dc:date>2014-08-01T10:24:33Z</dc:date>
    </item>
    <item>
      <title>Re: How to toggle Relative property in Chart (Straight table)</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345117#M574715</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank Rob, that was a great help. &lt;/P&gt;&lt;P&gt;I am stuck with an error message that says - &lt;/P&gt;&lt;P&gt;Error: Error in expression: ')' expected.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have no idea which expression it is referring to.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thank you again&lt;/P&gt;&lt;P&gt;cheers&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 23 Apr 2015 20:24:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-toggle-Relative-property-in-Chart-Straight-table/m-p/345117#M574715</guid>
      <dc:creator />
      <dc:date>2015-04-23T20:24:14Z</dc:date>
    </item>
  </channel>
</rss>

