<?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: If Statement using Variables for Colors in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/If-Statement-using-Variables-for-Colors/m-p/2128397#M91799</link>
    <description>&lt;P&gt;There was an extra parenthesis in the statement for the variable -- when I put that expression on its own there was no issue because nothing else was coming after, which is why it allowed an output I presume, but then when put in variable form it could not interact with the rest of the expression because of that extra parentheses. Was able to resolve this by putting the entire expression in the if statement and troubleshooting that way.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 13 Oct 2023 14:41:47 GMT</pubDate>
    <dc:creator>mhorsfall</dc:creator>
    <dc:date>2023-10-13T14:41:47Z</dc:date>
    <item>
      <title>If Statement using Variables for Colors</title>
      <link>https://community.qlik.com/t5/App-Development/If-Statement-using-Variables-for-Colors/m-p/2128115#M91787</link>
      <description>&lt;P&gt;I have an if statement:&amp;nbsp;&lt;/P&gt;
&lt;P&gt;IF($(vForecastVarianceMTD) &amp;lt; 0, &lt;BR /&gt;rgb(255, 0, 0),&lt;BR /&gt;rgb(0, 153, 0))&lt;/P&gt;
&lt;P&gt;The goal here is to make red if negative, and green if &amp;gt;= 0. I am currently getting the error: Error in expression: ')' expected. Not sure where the ')' is expected, but when I look at the sample script below, it outputs the full expression for the variable but it does not show the &amp;lt; 0, prior to showing the rgb part. When I put just the variable in a KPI it shows the value that I expect it to show. Any thoughts from the community?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 12 Oct 2023 19:03:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/If-Statement-using-Variables-for-Colors/m-p/2128115#M91787</guid>
      <dc:creator>mhorsfall</dc:creator>
      <dc:date>2023-10-12T19:03:35Z</dc:date>
    </item>
    <item>
      <title>Re: If Statement using Variables for Colors</title>
      <link>https://community.qlik.com/t5/App-Development/If-Statement-using-Variables-for-Colors/m-p/2128144#M91788</link>
      <description>&lt;P&gt;What is inside your&amp;nbsp;&lt;SPAN&gt;vForecastVarianceMTD variable and where are you trying to apply this ?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 12 Oct 2023 23:44:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/If-Statement-using-Variables-for-Colors/m-p/2128144#M91788</guid>
      <dc:creator>Lisa_P</dc:creator>
      <dc:date>2023-10-12T23:44:20Z</dc:date>
    </item>
    <item>
      <title>Re: If Statement using Variables for Colors</title>
      <link>https://community.qlik.com/t5/App-Development/If-Statement-using-Variables-for-Colors/m-p/2128165#M91789</link>
      <description>&lt;P&gt;seems your logic looks good,&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;STRONG&gt;can you try by placing the actual expression in if statement.&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;STRONG&gt;IF(sum(sales) &amp;lt; 0,rgb(255, 0, 0),rgb(0, 153, 0))&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 13 Oct 2023 02:47:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/If-Statement-using-Variables-for-Colors/m-p/2128165#M91789</guid>
      <dc:creator>anat</dc:creator>
      <dc:date>2023-10-13T02:47:28Z</dc:date>
    </item>
    <item>
      <title>Re: If Statement using Variables for Colors</title>
      <link>https://community.qlik.com/t5/App-Development/If-Statement-using-Variables-for-Colors/m-p/2128166#M91790</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;Please check the value of&amp;nbsp;$(DynamicTableName), what is the output ,&lt;BR /&gt;below is also another way to add color using &lt;SPAN class="lia-mentions-gte-v2-autocomplete"&gt;&lt;SPAN class="lia-mentions-gte-v2-trigger" contenteditable="false"&gt;#&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;IF($(DynamicTableName) &amp;lt; 0,&lt;BR /&gt;'#ff0000',&lt;BR /&gt;'#009900'&lt;BR /&gt;)&lt;/P&gt;</description>
      <pubDate>Fri, 13 Oct 2023 02:57:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/If-Statement-using-Variables-for-Colors/m-p/2128166#M91790</guid>
      <dc:creator>ajaykakkar93</dc:creator>
      <dc:date>2023-10-13T02:57:49Z</dc:date>
    </item>
    <item>
      <title>Re: If Statement using Variables for Colors</title>
      <link>https://community.qlik.com/t5/App-Development/If-Statement-using-Variables-for-Colors/m-p/2128397#M91799</link>
      <description>&lt;P&gt;There was an extra parenthesis in the statement for the variable -- when I put that expression on its own there was no issue because nothing else was coming after, which is why it allowed an output I presume, but then when put in variable form it could not interact with the rest of the expression because of that extra parentheses. Was able to resolve this by putting the entire expression in the if statement and troubleshooting that way.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 13 Oct 2023 14:41:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/If-Statement-using-Variables-for-Colors/m-p/2128397#M91799</guid>
      <dc:creator>mhorsfall</dc:creator>
      <dc:date>2023-10-13T14:41:47Z</dc:date>
    </item>
    <item>
      <title>Re: If Statement using Variables for Colors</title>
      <link>https://community.qlik.com/t5/App-Development/If-Statement-using-Variables-for-Colors/m-p/2128398#M91800</link>
      <description>&lt;P&gt;There was an extra parenthesis in the statement for the variable -- when I put that expression on its own there was no issue because nothing else was coming after, which is why it allowed an output I presume, but then when put in variable form it could not interact with the rest of the expression because of that extra parentheses. Was able to resolve this by putting the entire expression in the if statement and troubleshooting that way.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 13 Oct 2023 14:41:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/If-Statement-using-Variables-for-Colors/m-p/2128398#M91800</guid>
      <dc:creator>mhorsfall</dc:creator>
      <dc:date>2023-10-13T14:41:47Z</dc:date>
    </item>
  </channel>
</rss>

