<?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: Limit Legend (characters) in a Bar chart using Macro in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Limit-Legend-characters-in-a-Bar-chart-using-Macro/m-p/506229#M189267</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Balaji,&lt;/P&gt;&lt;P&gt;may be you can define the space area of your legend to get your goal.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;set Graph = ActiveDocument.Sheets("Main").CreateBarChart&lt;/P&gt;&lt;P&gt;Graph.AddDimension "ProductType"&lt;/P&gt;&lt;P&gt;Graph.AddDimension "Customer"&lt;/P&gt;&lt;P&gt;Graph.AddExpression "sum(Amount)"&lt;/P&gt;&lt;P&gt;set p = Graph.GetProperties&lt;/P&gt;&lt;P&gt;set leg = p.ChartProperties.Legend&lt;/P&gt;&lt;P&gt;leg.DockedPosition = 4&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 'free floating&lt;/P&gt;&lt;P&gt;leg.Position.Top = 100&lt;/P&gt;&lt;P&gt;leg.Position.Left = 100&lt;/P&gt;&lt;P&gt;leg.Position.Height = 200&lt;/P&gt;&lt;P&gt;leg.Position.Width = 200&lt;/P&gt;&lt;P&gt;leg.OnTop = true&lt;/P&gt;&lt;P&gt;leg.UserSized = true&lt;/P&gt;&lt;P&gt;Graph.SetProperties p&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Corrado.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 22 Oct 2013 14:42:52 GMT</pubDate>
    <dc:creator />
    <dc:date>2013-10-22T14:42:52Z</dc:date>
    <item>
      <title>Limit Legend (characters) in a Bar chart using Macro</title>
      <link>https://community.qlik.com/t5/QlikView/Limit-Legend-characters-in-a-Bar-chart-using-Macro/m-p/506228#M189266</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, &lt;/P&gt;&lt;P&gt;Can someone tell me how I can limit the number of characters in legends in a bar chart using macro? (Basically set the value which can be accessed using Properties &amp;gt; Presentation &amp;gt; Legend &amp;gt; Limit Legend. )&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Checked the available APIs, but couldn't find any relevant API.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Oct 2013 14:12:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Limit-Legend-characters-in-a-Bar-chart-using-Macro/m-p/506228#M189266</guid>
      <dc:creator />
      <dc:date>2013-10-22T14:12:12Z</dc:date>
    </item>
    <item>
      <title>Re: Limit Legend (characters) in a Bar chart using Macro</title>
      <link>https://community.qlik.com/t5/QlikView/Limit-Legend-characters-in-a-Bar-chart-using-Macro/m-p/506229#M189267</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Balaji,&lt;/P&gt;&lt;P&gt;may be you can define the space area of your legend to get your goal.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;set Graph = ActiveDocument.Sheets("Main").CreateBarChart&lt;/P&gt;&lt;P&gt;Graph.AddDimension "ProductType"&lt;/P&gt;&lt;P&gt;Graph.AddDimension "Customer"&lt;/P&gt;&lt;P&gt;Graph.AddExpression "sum(Amount)"&lt;/P&gt;&lt;P&gt;set p = Graph.GetProperties&lt;/P&gt;&lt;P&gt;set leg = p.ChartProperties.Legend&lt;/P&gt;&lt;P&gt;leg.DockedPosition = 4&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 'free floating&lt;/P&gt;&lt;P&gt;leg.Position.Top = 100&lt;/P&gt;&lt;P&gt;leg.Position.Left = 100&lt;/P&gt;&lt;P&gt;leg.Position.Height = 200&lt;/P&gt;&lt;P&gt;leg.Position.Width = 200&lt;/P&gt;&lt;P&gt;leg.OnTop = true&lt;/P&gt;&lt;P&gt;leg.UserSized = true&lt;/P&gt;&lt;P&gt;Graph.SetProperties p&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Corrado.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Oct 2013 14:42:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Limit-Legend-characters-in-a-Bar-chart-using-Macro/m-p/506229#M189267</guid>
      <dc:creator />
      <dc:date>2013-10-22T14:42:52Z</dc:date>
    </item>
    <item>
      <title>Re: Limit Legend (characters) in a Bar chart using Macro</title>
      <link>https://community.qlik.com/t5/QlikView/Limit-Legend-characters-in-a-Bar-chart-using-Macro/m-p/506230#M189268</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Found out the answer, need to use the API MaxStringLength to limit the number of characters in a chart.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Oct 2013 14:43:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Limit-Legend-characters-in-a-Bar-chart-using-Macro/m-p/506230#M189268</guid>
      <dc:creator />
      <dc:date>2013-10-22T14:43:27Z</dc:date>
    </item>
    <item>
      <title>Re: Limit Legend (characters) in a Bar chart using Macro</title>
      <link>https://community.qlik.com/t5/QlikView/Limit-Legend-characters-in-a-Bar-chart-using-Macro/m-p/506231#M189269</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;Could you please share the code that worked for you? I'm working on something similar (displaying the legend, on/off).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Sep 2014 20:42:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Limit-Legend-characters-in-a-Bar-chart-using-Macro/m-p/506231#M189269</guid>
      <dc:creator />
      <dc:date>2014-09-25T20:42:48Z</dc:date>
    </item>
  </channel>
</rss>

