<?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: Set Analysis within an if condtition in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Set-Analysis-within-an-if-condtition/m-p/814960#M471375</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks a lot, I used your second proposal:&lt;/P&gt;&lt;P&gt;If(count({StateB} distinct MyField) = fieldvaluecount('MyField'), &lt;SPAN style="font-size: 13.33px;"&gt;rgb(255,0,0), rgb(0,255,0))&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 17 Mar 2015 10:37:48 GMT</pubDate>
    <dc:creator />
    <dc:date>2015-03-17T10:37:48Z</dc:date>
    <item>
      <title>Set Analysis within an if condtition</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-within-an-if-condtition/m-p/814958#M471373</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey Guys,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm currently facing trouble with an if condition. More specifically my problem derives from a conditional formating (conditional colour) that I would like to apply to a textbox. Basis of my problem is that I have multiple alternate states and my textbox is set to StateA but the colour should depend on a selection made in StateB. Simply changing the entire alternate state of the object doesn't work since my expressions need to use StateA.&lt;/P&gt;&lt;P&gt;So this was my approach:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=if(SUM({[StateB]}GetSelectedCount(MyField)=0, RGB(400,0,0), RGB(0,0,400))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For some reasons this doesn't work and I wonder whether ther is another way to specify the alternate state StateB for my if condition without changing it for the whole object? Note that the SUM()-function is irrelevant for my calculations I just used it to set StateB.&lt;/P&gt;&lt;P&gt;All I want to do is have the object change the colour if MyField in StateB is not selected.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your help and have a good one,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Clemens&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 17 Mar 2015 07:58:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-within-an-if-condtition/m-p/814958#M471373</guid>
      <dc:creator />
      <dc:date>2015-03-17T07:58:34Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis within an if condtition</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-within-an-if-condtition/m-p/814959#M471374</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Starting with QV SR8 you can use alternate states in the get* functions:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=if(getselectedcount(MyField, 'StateB'), rgb(255,0,0), rgb(0,255,0)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In earlier versions you can use something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If(count({StateB} distinct MyField) = fieldvaluecount('MyField'), &lt;SPAN style="font-size: 13.3333330154419px;"&gt; rgb(255,0,0), rgb(0,255,0)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 17 Mar 2015 10:19:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-within-an-if-condtition/m-p/814959#M471374</guid>
      <dc:creator>Gysbert_Wassenaar</dc:creator>
      <dc:date>2015-03-17T10:19:25Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis within an if condtition</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-within-an-if-condtition/m-p/814960#M471375</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks a lot, I used your second proposal:&lt;/P&gt;&lt;P&gt;If(count({StateB} distinct MyField) = fieldvaluecount('MyField'), &lt;SPAN style="font-size: 13.33px;"&gt;rgb(255,0,0), rgb(0,255,0))&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 17 Mar 2015 10:37:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-within-an-if-condtition/m-p/814960#M471375</guid>
      <dc:creator />
      <dc:date>2015-03-17T10:37:48Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis within an if condtition</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-within-an-if-condtition/m-p/814961#M471376</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm now facing a follow-up problem and it'd be great if someone could help me with this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;While I wanted to use conditional colouring if no selection is made, I would now like to colour conditionally if a specific value is selected. Again I'm facing the problem of different alternate states: My object is StateA and my Selection will be made in StateB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So basically what I want to do is colour my StateA textbox in a different colour based on what selection is made in my StateB listbox.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any suggestions?&lt;/P&gt;&lt;P&gt;Thanks and all the best&lt;/P&gt;&lt;P&gt;Clemens&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Mar 2015 08:36:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-within-an-if-condtition/m-p/814961#M471376</guid>
      <dc:creator />
      <dc:date>2015-03-20T08:36:44Z</dc:date>
    </item>
  </channel>
</rss>

