<?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 array handling in Macro vbscript in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/array-handling-in-Macro-vbscript/m-p/373015#M138703</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;&amp;nbsp;&amp;nbsp;&amp;nbsp; Try this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;sub test&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;dim reset_y(50)&lt;/P&gt;&lt;P&gt;dim objID(50)&lt;/P&gt;&lt;P&gt;dim Objects&lt;/P&gt;&lt;P&gt;Objects = ActiveDocument.ActiveSheet.GetSheetObjects()&lt;/P&gt;&lt;P&gt;for i = lbound(Objects) to ubound(Objects)&lt;/P&gt;&lt;P&gt;If Objects(i).GetObjectID() = "Document\CH01" Then&lt;/P&gt;&lt;P&gt;pos = Objects(i).GetRect&lt;/P&gt;&lt;P&gt;reset_y(i)=pos.Top&lt;/P&gt;&lt;P&gt;msgbox(reset_y(i))&lt;/P&gt;&lt;P&gt;objID(i)=Objects(i).GetObjectID()&lt;/P&gt;&lt;P&gt;msgbox(objID(i))&lt;/P&gt;&lt;P&gt;'msgbox Objects(i).GetObjectID()&lt;/P&gt;&lt;P&gt;end if &lt;/P&gt;&lt;P&gt;next&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;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kaushik Solanki&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 29 May 2012 17:46:17 GMT</pubDate>
    <dc:creator>kaushiknsolanki</dc:creator>
    <dc:date>2012-05-29T17:46:17Z</dc:date>
    <item>
      <title>array handling in Macro vbscript</title>
      <link>https://community.qlik.com/t5/QlikView/array-handling-in-Macro-vbscript/m-p/373014#M138702</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;&lt;/P&gt;&lt;P&gt;I want to implement a case where , on clik of one button, I want to display few charts, and change the Y coordinate of hidden charts to 1&lt;/P&gt;&lt;P&gt;then in second button, rest of the charts are displayed, first are hidden, and the positions that were reduced to 1 are bought back(reset), so that thay appear at the desired places.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need this position changes in order to avoid the extra space that comes on the sheet because of the hidden objects.So, if I change the Y position to 1, the size of the sheet will corespond to only the objects that are visible.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Am using the macro below for capturing the Y position, but am not able to achieve this.&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;macro **************************************&lt;BR /&gt;sub hide1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;dim reset_y(50)&lt;BR /&gt;dim objID(50)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;dim Objects&lt;BR /&gt;Objects = ActiveDocument.ActiveSheet.GetSheetObjects()&lt;BR /&gt;for i = lbound(Objects) to ubound(Objects)&lt;BR /&gt;If Objects(i).GetObjectID()= CH37 Then&lt;BR /&gt;pos = Objects(i).GetRect&lt;BR /&gt;reset_y(i)=pos.Top&lt;BR /&gt;msgbox(reset_y(i))&lt;BR /&gt;objID=Objects(i).GetObjectID()&lt;BR /&gt;msgbox(objID(i))&lt;BR /&gt;end if &lt;BR /&gt;next&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;end sub &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;﻿&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;﻿&lt;/SPAN&gt;Please help me on this macro.&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;﻿&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 May 2012 15:18:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/array-handling-in-Macro-vbscript/m-p/373014#M138702</guid>
      <dc:creator>sonikajain</dc:creator>
      <dc:date>2012-05-29T15:18:10Z</dc:date>
    </item>
    <item>
      <title>array handling in Macro vbscript</title>
      <link>https://community.qlik.com/t5/QlikView/array-handling-in-Macro-vbscript/m-p/373015#M138703</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;&amp;nbsp;&amp;nbsp;&amp;nbsp; Try this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;sub test&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;dim reset_y(50)&lt;/P&gt;&lt;P&gt;dim objID(50)&lt;/P&gt;&lt;P&gt;dim Objects&lt;/P&gt;&lt;P&gt;Objects = ActiveDocument.ActiveSheet.GetSheetObjects()&lt;/P&gt;&lt;P&gt;for i = lbound(Objects) to ubound(Objects)&lt;/P&gt;&lt;P&gt;If Objects(i).GetObjectID() = "Document\CH01" Then&lt;/P&gt;&lt;P&gt;pos = Objects(i).GetRect&lt;/P&gt;&lt;P&gt;reset_y(i)=pos.Top&lt;/P&gt;&lt;P&gt;msgbox(reset_y(i))&lt;/P&gt;&lt;P&gt;objID(i)=Objects(i).GetObjectID()&lt;/P&gt;&lt;P&gt;msgbox(objID(i))&lt;/P&gt;&lt;P&gt;'msgbox Objects(i).GetObjectID()&lt;/P&gt;&lt;P&gt;end if &lt;/P&gt;&lt;P&gt;next&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;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kaushik Solanki&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 May 2012 17:46:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/array-handling-in-Macro-vbscript/m-p/373015#M138703</guid>
      <dc:creator>kaushiknsolanki</dc:creator>
      <dc:date>2012-05-29T17:46:17Z</dc:date>
    </item>
  </channel>
</rss>

