<?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: getfieldselection into variable not working in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790626#M1210595</link>
    <description>&lt;P&gt;i create a new variable with the same configuration and it works &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 11 Mar 2021 16:41:43 GMT</pubDate>
    <dc:creator>qlikviewuser20</dc:creator>
    <dc:date>2021-03-11T16:41:43Z</dc:date>
    <item>
      <title>getfieldselection into variable not working</title>
      <link>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790413#M1210570</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have a strange behaviour of the GetfieldSelection function.&lt;/P&gt;&lt;P&gt;I have a field loaded into the script with AUTOGENERATE :&lt;/P&gt;&lt;P&gt;Annee_Test:&lt;BR /&gt;LOAD&lt;BR /&gt;$(vAnneeMin) + rowno()-1 as _Annee_Test&lt;BR /&gt;AUTOGENERATE $(vAnneeMax) - $(vAnneeMin) + 1;&lt;/P&gt;&lt;P&gt;In the application , i added a trigger onselect on the field _Annee_test and define a variable vAnneeTest: =GetFieldSelections(_Annee_Test)&lt;/P&gt;&lt;P&gt;Than i have a listbox with _Annee_Test and when i display the variable vAnneeTest it takes the value of _Annee_Test but when i choose&amp;nbsp; &amp;nbsp;the max year or the max year-1 it stuck on the last selected value:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="qlikviewuser20_2-1615455021742.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/50933i58A307F83F879E79/image-size/medium?v=v2&amp;amp;px=400" role="button" title="qlikviewuser20_2-1615455021742.png" alt="qlikviewuser20_2-1615455021742.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="qlikviewuser20_1-1615454995199.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/50932i982F37B5AEDE0A55/image-size/medium?v=v2&amp;amp;px=400" role="button" title="qlikviewuser20_1-1615454995199.png" alt="qlikviewuser20_1-1615454995199.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 11 Mar 2021 09:30:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790413#M1210570</guid>
      <dc:creator>qlikviewuser20</dc:creator>
      <dc:date>2021-03-11T09:30:54Z</dc:date>
    </item>
    <item>
      <title>Re: getfieldselection into variable not working</title>
      <link>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790432#M1210571</link>
      <description>&lt;P&gt;I had a bit of trouble following along:&lt;/P&gt;&lt;P&gt;1) Your field appears to be Annee_Test, not _Annee_Test (with a leading underscore)&lt;/P&gt;&lt;P&gt;2) Why did you add a trigger? What does the trigger do?&lt;/P&gt;</description>
      <pubDate>Thu, 11 Mar 2021 10:06:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790432#M1210571</guid>
      <dc:creator>Or</dc:creator>
      <dc:date>2021-03-11T10:06:40Z</dc:date>
    </item>
    <item>
      <title>Re: getfieldselection into variable not working</title>
      <link>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790457#M1210574</link>
      <description>&lt;P&gt;1 ) it's _Annee_Test ? I just change the label in the listbox&lt;/P&gt;&lt;P&gt;2) I added a trigger on select to get the value of _Annee_Test into the variable vAnneeTest (Same result if i just declare the variable as =getfieldSlections(_Annee_Test)&lt;/P&gt;</description>
      <pubDate>Thu, 11 Mar 2021 11:03:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790457#M1210574</guid>
      <dc:creator>qlikviewuser20</dc:creator>
      <dc:date>2021-03-11T11:03:23Z</dc:date>
    </item>
    <item>
      <title>Re: getfieldselection into variable not working</title>
      <link>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790460#M1210576</link>
      <description>&lt;P&gt;1) OK - obviously, there was no way to know that based on the image, so had to make sure that wasn't the issue&lt;/P&gt;&lt;P&gt;2) I'm not sure why you're doing it with a trigger instead of using a regular variable. OnSelect triggers are known to be somewhat wonky, particularly in the ajax client (for example, &lt;A href="https://community.qlik.com/t5/QlikView-App-Dev/Onselect-Trigger-not-firing-when-selected-through-a-button/m-p/1435039" target="_blank"&gt;https://community.qlik.com/t5/QlikView-App-Dev/Onselect-Trigger-not-firing-when-selected-through-a-button/m-p/1435039&lt;/A&gt; ) - are you able to use OnChange instead? If so, does that work as expected?&lt;/P&gt;</description>
      <pubDate>Thu, 11 Mar 2021 11:09:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790460#M1210576</guid>
      <dc:creator>Or</dc:creator>
      <dc:date>2021-03-11T11:09:01Z</dc:date>
    </item>
    <item>
      <title>Re: getfieldselection into variable not working</title>
      <link>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790477#M1210579</link>
      <description>&lt;P&gt;same thing with OnChange&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 11 Mar 2021 11:53:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790477#M1210579</guid>
      <dc:creator>qlikviewuser20</dc:creator>
      <dc:date>2021-03-11T11:53:40Z</dc:date>
    </item>
    <item>
      <title>Re: getfieldselection into variable not working</title>
      <link>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790487#M1210581</link>
      <description>&lt;P&gt;I've attempted to test this locally and it works fine on my end, no matter which selections I make (QV 12.5 SR3).&lt;/P&gt;&lt;P&gt;You could try using a value of =_Annee_Test (instead of GetFieldSelections) and see if that works - obviously it'll only work for one year but it's worth testing out. You could also try with Concat(distinct Year,';').&lt;/P&gt;</description>
      <pubDate>Thu, 11 Mar 2021 12:18:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790487#M1210581</guid>
      <dc:creator>Or</dc:creator>
      <dc:date>2021-03-11T12:18:55Z</dc:date>
    </item>
    <item>
      <title>Re: getfieldselection into variable not working</title>
      <link>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790488#M1210582</link>
      <description>&lt;P&gt;I've attempted to test this locally and it works fine on my end, no matter which selections I make (QV 12.5 SR3).&lt;/P&gt;&lt;P&gt;You could try using a value of =_Annee_Test (instead of GetFieldSelections) and see if that works - obviously it'll only work for one year but it's worth testing out. You could also try with Concat(distinct Year,';').&lt;/P&gt;</description>
      <pubDate>Thu, 11 Mar 2021 12:18:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790488#M1210582</guid>
      <dc:creator>Or</dc:creator>
      <dc:date>2021-03-11T12:18:57Z</dc:date>
    </item>
    <item>
      <title>Re: getfieldselection into variable not working</title>
      <link>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790554#M1210586</link>
      <description>&lt;P&gt;it is really weird . I also do the same thing in a separate application and it works.&lt;/P&gt;&lt;P&gt;But still not working in the other application , i also tried the web view and same thing&lt;/P&gt;</description>
      <pubDate>Thu, 11 Mar 2021 14:29:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790554#M1210586</guid>
      <dc:creator>qlikviewuser20</dc:creator>
      <dc:date>2021-03-11T14:29:02Z</dc:date>
    </item>
    <item>
      <title>Re: getfieldselection into variable not working</title>
      <link>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790558#M1210587</link>
      <description>&lt;P&gt;Weird indeed. Perhaps you have competing triggers? At this point I don't really know what else to suggest... maybe try with a new variable / new name for the field and see if that fixes it.&lt;/P&gt;</description>
      <pubDate>Thu, 11 Mar 2021 14:31:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790558#M1210587</guid>
      <dc:creator>Or</dc:creator>
      <dc:date>2021-03-11T14:31:01Z</dc:date>
    </item>
    <item>
      <title>Re: getfieldselection into variable not working</title>
      <link>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790626#M1210595</link>
      <description>&lt;P&gt;i create a new variable with the same configuration and it works &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 11 Mar 2021 16:41:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/getfieldselection-into-variable-not-working/m-p/1790626#M1210595</guid>
      <dc:creator>qlikviewuser20</dc:creator>
      <dc:date>2021-03-11T16:41:43Z</dc:date>
    </item>
  </channel>
</rss>

