<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://community.appian.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>If Statement show and hide</title><link>https://community.appian.com/discussions/f/rules/24636/if-statement-show-and-hide</link><description>Goal: name1, name2, name3 (show and hide comas in between and names if they are selected) 
 Default is N/A if no names are selected 
 What I have tried: if(isnull({pv!process.name1, pv!process.name2,pv!process.name3 }), &amp;quot;N/A&amp;quot;,&amp;quot;&amp;quot;) &amp;amp; if(isnull(pv!process</description><dc:language>en-US</dc:language><generator>Telligent Community 12</generator><item><title>RE: If Statement show and hide</title><link>https://community.appian.com/thread/95250?ContentTypeID=1</link><pubDate>Thu, 19 May 2022 01:01:47 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:2113cbb8-42ca-40d2-ba07-ec1a716a6b96</guid><dc:creator>Naresh</dc:creator><description>&lt;p&gt;Yes, It will work. Create an expression rule with this logic and call that rule in your email node.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="xml"&gt;ex: 
rule!returnName(
name1: pv!name1,
name2: pv!name2,
name3: pv!name3
)&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: If Statement show and hide</title><link>https://community.appian.com/thread/95247?ContentTypeID=1</link><pubDate>Wed, 18 May 2022 20:40:02 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:29da5490-0dcb-47e6-acfc-d56803be6152</guid><dc:creator>oludareo0002</dc:creator><description>&lt;p&gt;oh sorry maybe I wasn&amp;#39;t clear but this was for a email, does the same logic apply?&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: If Statement show and hide</title><link>https://community.appian.com/thread/95246?ContentTypeID=1</link><pubDate>Wed, 18 May 2022 20:34:48 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:7a1cc2c6-9cc4-4fec-a106-960dfb5751a1</guid><dc:creator>Naresh</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;You can use the following logic.&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="xml"&gt;a!localVariables(
  local!name: if(
    all(
      fn!isnull, 
      {
        ri!name1,
        ri!name2,
        ri!name3
      }
    ), 
    &amp;quot;N/A&amp;quot;,
    concat(
      if(
        a!isNullOrEmpty(ri!name1),
        &amp;quot;&amp;quot;,
        ri!name1
      ),
      if(
        a!isNullOrEmpty(ri!name2),
        &amp;quot;&amp;quot;,
        if(
          a!isNullOrEmpty(ri!name1),
          ri!name2,
          {
            &amp;quot;, &amp;quot;,
            ri!name2
          }
        )
      ),
      if(
        a!isNullOrEmpty(ri!name3),
        &amp;quot;&amp;quot;,
        if(
          and(
            a!isNullOrEmpty(ri!name1),
            a!isNullOrEmpty(ri!name2)
          ),
          ri!name3,
          {
            &amp;quot;, &amp;quot;,
            ri!name3
          }
        )
      )
    )
  ),
  local!name
)&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>