<?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>validation</title><link>https://community.appian.com/discussions/f/rules/24557/validation</link><description>Hi, 
 
 i have a picker field when i select some particular users names it has to show validation message else no 
 i have written like this but it is showing for all users whoever i select in picker field</description><dc:language>en-US</dc:language><generator>Telligent Community 12</generator><item><title>RE: validation</title><link>https://community.appian.com/thread/95039?ContentTypeID=1</link><pubDate>Thu, 12 May 2022 18:48:40 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:384edc2c-e536-4aff-bc64-54111f51fe8e</guid><dc:creator>Mike Schmitt</dc:creator><description>&lt;p&gt;Please note also that if you&amp;#39;re on a reasonably modern version of Appian, you should be using the newer function &lt;strong&gt;&lt;em&gt;a!isUserMemberOfGroups()&lt;/em&gt;&lt;/strong&gt;, which automatically handles checking many groups (and built-in logic for requiring the user to be a member of &lt;em&gt;all&lt;/em&gt; listed groups or &lt;em&gt;any&lt;/em&gt; listed groups).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: validation</title><link>https://community.appian.com/thread/95023?ContentTypeID=1</link><pubDate>Thu, 12 May 2022 12:18:29 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:d578801f-5880-4413-8fec-649eaffaf745</guid><dc:creator>KM</dc:creator><description>&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt; if(
        isusermemberofgroup(
          ri!approver_txt,
          {
            cons!CR_GRP_BOARD_OF_DIRECTORS_GROUP
          }
        ),
        cons!CR_NEXT_AUTHORITY_VALIDATION_MESSAGE[3],
        if(
          isusermemberofgroup(
            ri!approver_txt,
            {
              cons!CR_APP_GRP_HOC_GROUP,
              
            }
          ),
          cons!CR_NEXT_AUTHORITY_VALIDATION_MESSAGE[3],
          if(
            isusermemberofgroup(
              ri!approver_txt,
              {
                cons!CR_APP_GRP_DCEO_GROUP
              }
            ),
            cons!CR_NEXT_AUTHORITY_VALIDATION_MESSAGE[3],
            if(
              isusermemberofgroup(
                ri!approver_txt,
                {
                  cons!CR_APP_GRP_CEO_GROUP
                }
              ),
              cons!CR_NEXT_AUTHORITY_VALIDATION_MESSAGE[3],
              null
            )
          )
        )
      )&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;this worked&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: validation</title><link>https://community.appian.com/thread/95022?ContentTypeID=1</link><pubDate>Thu, 12 May 2022 10:04:56 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:d78bb726-ee48-411e-8d6b-77bc890e71b3</guid><dc:creator>KM</dc:creator><description>&lt;p&gt;this logic will give this error&lt;/p&gt;
&lt;p&gt;&lt;img src="/resized-image/__size/320x240/__key/communityserver-discussions-components-files/15/pastedimage1652349906341v1.png" alt=" " /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: validation</title><link>https://community.appian.com/thread/95015?ContentTypeID=1</link><pubDate>Thu, 12 May 2022 08:22:46 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:82a8d50f-c924-4b1c-a167-775807aba7fc</guid><dc:creator>venkyuppala09</dc:creator><description>&lt;p&gt;Check with below code, If it throws same error check the groups security.&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;if(
  not(isusernametaken(ri!approver_txt)),
  cons!CR_NEXT_AUTHORITY_VALIDATION_MESSAGE[2],
  if(
    ri!approver_txt = loggedInUser(),
    cons!CR_NEXT_AUTHORITY_VALIDATION_MESSAGE[1],
    if(
      a!isUserMemberOfGroup(
        ri!approver_txt,
        {
          cons!CR_GRP_ALL_CCC_USER_GROUP,
          cons!CR_GRP_BOARD_OF_DIRECTORS_GROUP
        }
      ),
      cons!CR_NEXT_AUTHORITY_VALIDATION_MESSAGE[3],
      null
    )
  )
)&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: validation</title><link>https://community.appian.com/thread/95014?ContentTypeID=1</link><pubDate>Thu, 12 May 2022 07:59:33 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:85b5720b-f11c-448b-bc6c-ac7de8a492d3</guid><dc:creator>KM</dc:creator><description>&lt;p&gt;if i make changes like that which will give me error like below&lt;/p&gt;
&lt;p&gt;&lt;img src="/resized-image/__size/320x240/__key/communityserver-discussions-components-files/15/pastedimage1652342392587v1.png" alt=" " /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: validation</title><link>https://community.appian.com/thread/95013?ContentTypeID=1</link><pubDate>Thu, 12 May 2022 07:54:00 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:7e1bb18c-9c51-41c3-be0c-4898ec0680f1</guid><dc:creator>venkyuppala09</dc:creator><description>&lt;p&gt;Isusermemberofgroup returns boolean value but here your checking with Text/user type, Don&amp;#39;t check the value use&amp;nbsp;&lt;span&gt;Isusermemberofgroup&amp;nbsp;alone like below.&lt;br /&gt;&lt;img alt=" " src="/resized-image/__size/320x240/__key/communityserver-discussions-components-files/15/pastedimage1652342056375v1.png" /&gt;&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: validation</title><link>https://community.appian.com/thread/95011?ContentTypeID=1</link><pubDate>Thu, 12 May 2022 07:29:37 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:479bf40f-cdf1-4f4f-a010-a41a266d68b4</guid><dc:creator>KM</dc:creator><description>&lt;p&gt;&lt;img src="/resized-image/__size/320x240/__key/communityserver-discussions-components-files/15/pastedimage1652340544811v1.png" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;i have written like this but message 3 is not showing when i select ccc_user name&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: validation</title><link>https://community.appian.com/thread/94905?ContentTypeID=1</link><pubDate>Tue, 10 May 2022 13:19:35 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:9ec9f96e-9d1c-42a7-b194-043a061b49c3</guid><dc:creator>Naresh</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;you can update you logic like below&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="xml"&gt;if(
    a!isUserMemberOfGroup(
    ri!approver_txt,
    cons!CR_GRP_ALL_CCC_USER_GROUP
    ),
    cons!CR_NEXT_AUTHORITY_VALIDATION_MESSAGE[3],
    &amp;quot;&amp;quot;
)&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: validation</title><link>https://community.appian.com/thread/94893?ContentTypeID=1</link><pubDate>Tue, 10 May 2022 09:51:22 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:0efbf46d-f384-40e4-aec1-ef92ee3891bb</guid><dc:creator>Stefan Helzle</dc:creator><description>&lt;p&gt;Thanks Laurens, I did not spot that.&lt;/p&gt;
&lt;p&gt;You are not checking for the selected user, but always for the logged in user, which is you.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: validation</title><link>https://community.appian.com/thread/94892?ContentTypeID=1</link><pubDate>Tue, 10 May 2022 09:24:38 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:99a2d132-f55e-43a1-8342-5d9a572d18c2</guid><dc:creator>laurensw</dc:creator><description>&lt;p&gt;Please note that function loggedInUser() does not have parameters. You can remove it and pass the username as first parameter of the a!isUserMemberOfGroup() function.&lt;/p&gt;
&lt;p&gt;If this does not resolve your issue you may not have enough rights to view the users or group contents you are requesting. Check group visibility policies for this.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: validation</title><link>https://community.appian.com/thread/94891?ContentTypeID=1</link><pubDate>Tue, 10 May 2022 08:53:20 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:d918afa5-6c5a-4713-a8aa-e5a5e0f37813</guid><dc:creator>KM</dc:creator><description>&lt;p&gt;my logic is showing warning message to all selected users but not some particular user&amp;nbsp;&lt;/p&gt;
&lt;p&gt;for ex: all users- abc,xyz,pqr,wtu,ijk&lt;/p&gt;
&lt;p&gt;for users - abc,wtu when i select these users then it has to show warning message&lt;/p&gt;
&lt;p&gt;my logic is showing warning message when i select pqr/xyz&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: validation</title><link>https://community.appian.com/thread/94888?ContentTypeID=1</link><pubDate>Tue, 10 May 2022 08:36:53 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:4d43b702-3ae9-4452-94da-85148563d23f</guid><dc:creator>Stefan Helzle</dc:creator><description>&lt;p&gt;OK, but what is wrong with it? What did you do to test your logic?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: validation</title><link>https://community.appian.com/thread/94887?ContentTypeID=1</link><pubDate>Tue, 10 May 2022 08:23:57 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:b006b90c-ba64-44a6-a712-d527633ee171</guid><dc:creator>KM</dc:creator><description>&lt;p&gt;yes, if the selected user is belongs to that user then show error/warning message&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: validation</title><link>https://community.appian.com/thread/94886?ContentTypeID=1</link><pubDate>Tue, 10 May 2022 08:14:27 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:a68c44bd-f79d-4a2a-a560-dbd4cf8f7a65</guid><dc:creator>Stefan Helzle</dc:creator><description>&lt;p&gt;Your logic shows the message in case the user is a member of that group. Is that what you want?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>