<?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 set a variable and read it later in the same trigger in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800714#M282589</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It's not a problem between triggers, only 1 trigger with these 3 actions.&lt;/P&gt;&lt;P&gt;You are right, I can't do it in one expression, because the 2nd step is to get all entries of another level to ensure they are shown as well as the original selection&lt;/P&gt;&lt;P&gt;Any ideas how to store the selection elsewhere?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 10 Nov 2014 15:14:48 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-11-10T15:14:48Z</dc:date>
    <item>
      <title>how to set a variable and read it later in the same trigger</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800711#M282586</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 try to change selections in listbox2 due to selections in listbox1.&lt;/P&gt;&lt;P&gt;To do so I created an onSelction trigger on listbox1 with the following actions:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;get the current selection in listbox1 and set it to the variable vMySelection.&lt;/LI&gt;&lt;LI&gt;some changes... &lt;/LI&gt;&lt;LI&gt;change the selection in listbox2 to the value of variable vMySelection&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;But I always get the value that was set before the last execution of the trigger, not the value I set in the first action &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When are variables in trigger evaluated and how can I work around that behaviour?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I use QV 11.2 and the solution has to work with the ajax client.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot&lt;/P&gt;&lt;P&gt;Klaus&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Nov 2014 14:57:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800711#M282586</guid>
      <dc:creator />
      <dc:date>2014-11-10T14:57:25Z</dc:date>
    </item>
    <item>
      <title>Re: how to set a variable and read it later in the same trigger</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800712#M282587</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I know what you describe is a right pain, but unfortunately that is the way QlikView works.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Nov 2014 15:03:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800712#M282587</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-11-10T15:03:55Z</dc:date>
    </item>
    <item>
      <title>Re: how to set a variable and read it later in the same trigger</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800713#M282588</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;There is no order in trigger handling, I'm even convinced that all triggers that need to be handled use the same state as before any of the triggers were executed. So your solution with a variable does not work. But I can't imagine that you cannot do the changes you mention in one single expression, which you could use to do a selection in lb2 directly.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Nov 2014 15:09:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800713#M282588</guid>
      <dc:creator>stigchel</dc:creator>
      <dc:date>2014-11-10T15:09:04Z</dc:date>
    </item>
    <item>
      <title>Re: how to set a variable and read it later in the same trigger</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800714#M282589</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It's not a problem between triggers, only 1 trigger with these 3 actions.&lt;/P&gt;&lt;P&gt;You are right, I can't do it in one expression, because the 2nd step is to get all entries of another level to ensure they are shown as well as the original selection&lt;/P&gt;&lt;P&gt;Any ideas how to store the selection elsewhere?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Nov 2014 15:14:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800714#M282589</guid>
      <dc:creator />
      <dc:date>2014-11-10T15:14:48Z</dc:date>
    </item>
    <item>
      <title>Re: how to set a variable and read it later in the same trigger</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800715#M282590</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I had exactly the same issue and got the response back from support:&lt;/P&gt;&lt;P&gt;'Actions are not carried out sequentially on buttons, they are all expanded and executed at the same time.'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That was in April 2010 and although I raised an 'idea' to provide an option to perform sequential processing, nothing came of it &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/sad.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The only alternative is a macro (shudder).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Gordon&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Nov 2014 15:20:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800715#M282590</guid>
      <dc:creator />
      <dc:date>2014-11-10T15:20:41Z</dc:date>
    </item>
    <item>
      <title>Re: how to set a variable and read it later in the same trigger</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800716#M282591</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm afraid there is some misunderstanding:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- Let me rephrase the bit about triggers: all actions in a trigger use the same state, you cannot use changes in the process&lt;/P&gt;&lt;P&gt;- I think you can do it in one expression, at least i cannot imagine why you could not&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you explain what you mean by all entries of another level?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Nov 2014 15:22:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800716#M282591</guid>
      <dc:creator>stigchel</dc:creator>
      <dc:date>2014-11-10T15:22:34Z</dc:date>
    </item>
    <item>
      <title>Re: how to set a variable and read it later in the same trigger</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800717#M282592</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I fear macros won't work in Ajax-Client&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks for clarification about the execution order of actions &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Klaus&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Nov 2014 15:45:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800717#M282592</guid>
      <dc:creator />
      <dc:date>2014-11-10T15:45:30Z</dc:date>
    </item>
    <item>
      <title>Re: how to set a variable and read it later in the same trigger</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800718#M282593</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;we have flattened Hierarchie in a table.&lt;/P&gt;&lt;P&gt;In an extension this hierarchie is to be shown as follows:&lt;/P&gt;&lt;P&gt;alle Entries of level 1 and 2 and the selected entries on level 3 (listbox1)&lt;/P&gt;&lt;P&gt;Listbox2 has the ids of all entries&lt;/P&gt;&lt;P&gt;When listbox1 is selected, the actions do&lt;/P&gt;&lt;P&gt;save the selection in the variable&lt;/P&gt;&lt;P&gt;select listbox level to levels 1 and 2&lt;/P&gt;&lt;P&gt;select the possibles in listbox2&lt;/P&gt;&lt;P&gt;toggle the entries from the variable&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in sql I would use a union all on the selected entries and the entries with level 1 and 2,&lt;/P&gt;&lt;P&gt;how can that be achieved in 1 expression?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BTW: the actions are running in the right order, but the value in the variable is not updated, as you explained &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Klaus&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Nov 2014 15:59:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800718#M282593</guid>
      <dc:creator />
      <dc:date>2014-11-10T15:59:23Z</dc:date>
    </item>
    <item>
      <title>Re: how to set a variable and read it later in the same trigger</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800719#M282594</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hmm, difficult to understand without knowing your setup and data model, however I think I have thought of something you can try. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can try creating an alternate state, then instead of storing the selection in a variable, make the selection in the alternate state (you can use triggers for this as well). Instead of the variable you can then later read the stored selection with a function that takes set analysis e.g. Only({MyAltState} MyField).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Nov 2014 16:29:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800719#M282594</guid>
      <dc:creator>stigchel</dc:creator>
      <dc:date>2014-11-10T16:29:56Z</dc:date>
    </item>
    <item>
      <title>Re: how to set a variable and read it later in the same trigger</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800720#M282595</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Piet,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;that sounds genious. I used them before but did not think of them for this purpose.&lt;/P&gt;&lt;P&gt;I'll try that tomorrow and give you feedback.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks and bye&lt;/P&gt;&lt;P&gt;Klaus&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Nov 2014 17:18:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800720#M282595</guid>
      <dc:creator />
      <dc:date>2014-11-10T17:18:19Z</dc:date>
    </item>
    <item>
      <title>Re: how to set a variable and read it later in the same trigger</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800721#M282596</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Check this thread &lt;A _jive_internal="true" href="https://community.qlik.com/thread/41644"&gt;http://community.qlik.com/thread/41644&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Christof Schwarz (Presales Solution Architect) presented a work around on that thread.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Good luck....please post your results for future reference by others&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards&lt;/P&gt;&lt;P&gt;Suresh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Nov 2014 19:41:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800721#M282596</guid>
      <dc:creator>smqlikview</dc:creator>
      <dc:date>2014-11-20T19:41:08Z</dc:date>
    </item>
    <item>
      <title>Re: how to set a variable and read it later in the same trigger</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800722#M282597</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks to Piet and Suresh,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;but due to budget restrictions, we do not implement that feature, but have an alternate process defined.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind Regards&lt;/P&gt;&lt;P&gt;Klaus&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Dec 2014 12:06:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-set-a-variable-and-read-it-later-in-the-same-trigger/m-p/800722#M282597</guid>
      <dc:creator />
      <dc:date>2014-12-03T12:06:25Z</dc:date>
    </item>
  </channel>
</rss>

