<?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: How to remove a field in a multibox, using a macro ? in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-to-remove-a-field-in-a-multibox-using-a-macro/m-p/626124#M681282</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;By Selections inside macro- all I mean is the Select "M1" phrase...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 11 Mar 2014 23:00:19 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-03-11T23:00:19Z</dc:date>
    <item>
      <title>How to remove a field in a multibox, using a macro ?</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-remove-a-field-in-a-multibox-using-a-macro/m-p/626123#M681281</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;I have a field in the document, by the name &lt;STRONG&gt;Market (with data M1,M2 and M3)&lt;/STRONG&gt;. &lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;I have a multibox with fields &lt;STRONG&gt;A, B and C(for each of the markets present in the field called, Market)&lt;/STRONG&gt;. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;Once the document is reloaded and reduced, based upon the values present in the Market field, the fields in the multibox should be removed.i.e, if after reduction, the Market field does'nt have the value, M3 - the field called C should be removed from the multibox, as well.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;So far, i could get upto here: But I do not want to make these selections inside macro - is there any other way ??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sub macrocode&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; set mb =&amp;nbsp; ActiveDocument.GetSheetObject("MB01") //fetch multibox id&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; set f1 = ActiveDocument.Fields("Market").Select "M1"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if f1 &amp;lt;&amp;gt; 1 //if it cant find a value M1 in the field, Market&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; mb.RemoveField 0&amp;nbsp;&amp;nbsp;&amp;nbsp; //removing the corresponding field(say A) from the multbox (making sure that A is the first field in the multibox)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; end if&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; else&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; //Same condition as above for a different market....so on&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Mar 2014 22:55:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-remove-a-field-in-a-multibox-using-a-macro/m-p/626123#M681281</guid>
      <dc:creator />
      <dc:date>2014-03-11T22:55:25Z</dc:date>
    </item>
    <item>
      <title>Re: How to remove a field in a multibox, using a macro ?</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-remove-a-field-in-a-multibox-using-a-macro/m-p/626124#M681282</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;By Selections inside macro- all I mean is the Select "M1" phrase...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Mar 2014 23:00:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-remove-a-field-in-a-multibox-using-a-macro/m-p/626124#M681282</guid>
      <dc:creator />
      <dc:date>2014-03-11T23:00:19Z</dc:date>
    </item>
    <item>
      <title>Re: How to remove a field in a multibox, using a macro ?</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-remove-a-field-in-a-multibox-using-a-macro/m-p/626125#M681283</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;Create two multiBoxes with different set of fields then show and hide based on the selections like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In Properties -&amp;gt; Layout -&amp;gt; Show Conditional&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=If(GetFieldSelections(Market) = 'M1', 1, 0) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps you, if it not works then attach some sample file.&amp;nbsp; Using Macro is not best option it doesn't work as expected sometimes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;jagan.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Mar 2014 03:11:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-remove-a-field-in-a-multibox-using-a-macro/m-p/626125#M681283</guid>
      <dc:creator>jagan</dc:creator>
      <dc:date>2014-03-13T03:11:10Z</dc:date>
    </item>
  </channel>
</rss>

