<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.aras.com/community/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>How do I get the User-Name instead of ID in email notification (html)</title><link>https://www.aras.com/community/f/development/6675/how-do-i-get-the-user-name-instead-of-id-in-email-notification-html</link><description>Hi Community, 
 I&amp;#39;ve created an email notification coupled to a LifeCycle state. The creator of the part has to be mentioned in the notification but I only get the ID. 
 My HTML: ...${created_by_id}... 
 How can I change the ID to User-Name? I want to</description><dc:language>ja-JP</dc:language><generator>Telligent Community 12</generator><item><title>RE: How do I get the User-Name instead of ID in email notification (html)</title><link>https://www.aras.com/community/thread/4113?ContentTypeID=1</link><pubDate>Tue, 17 Dec 2019 07:35:15 GMT</pubDate><guid isPermaLink="false">916d3f7e-8ddc-42f8-8d45-380822f51406:1b0685f4-c058-4e21-a2bc-8d4019c6f9ff</guid><dc:creator>Dave259</dc:creator><description>&lt;p&gt;Hi Chris,&lt;/p&gt;
&lt;p&gt;thank you for your competent and detailed answer. It worked at the first try &lt;span class="emoticon" data-url="https://www.aras.com/community/cfs-file/__key/system/emoji/1f603.svg" title="Smiley"&gt;&amp;#x1f603;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;p&gt;Dave&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How do I get the User-Name instead of ID in email notification (html)</title><link>https://www.aras.com/community/thread/4109?ContentTypeID=1</link><pubDate>Mon, 16 Dec 2019 21:24:12 GMT</pubDate><guid isPermaLink="false">916d3f7e-8ddc-42f8-8d45-380822f51406:34c76bf5-d2b8-4a5b-b68d-528baf9fc437</guid><dc:creator>Christopher Gillis</dc:creator><description>&lt;p&gt;Hi Dave,&lt;/p&gt;
&lt;p&gt;The variables that you&amp;#39;re using inside of the E-Mail Message item fields basically represent XPath expressions to the data you&amp;#39;re looking for. With this in mind, I&amp;#39;d recommend first&amp;nbsp;just running a simple AML query on your Part to see what the format of the result is and what information you have access to. This should help you better figure out how to access the name of the&amp;nbsp;&lt;em&gt;&lt;/em&gt;creator of the Part. If you&amp;#39;re new to Aras or just unfamiliar with AML, I&amp;#39;d recommend checking out our &lt;a href="/b/english/posts/aml-basics"&gt;intro blog post&lt;/a&gt;.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;In this case, we just want to run a simple&amp;nbsp;&lt;em&gt;get&lt;/em&gt; on our Part to see what the result looks like. I&amp;#39;ve included a sample AML request below on a test part in one of my local instances. Note that I&amp;#39;ve used an intentionally specific&amp;nbsp;&lt;em&gt;select&lt;/em&gt; attribute to keep the size of the result down for demonstration purposes.&lt;/p&gt;
&lt;p&gt;AML:&lt;/p&gt;
&lt;div&gt;
&lt;div&gt;&lt;em&gt;&amp;lt;AML&amp;gt;&lt;/em&gt;&lt;/div&gt;
&lt;div&gt;&lt;em&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;Item&amp;nbsp;type=&amp;quot;Part&amp;quot;&amp;nbsp;action=&amp;quot;get&amp;quot;&amp;nbsp;select=&amp;quot;created_by_id&amp;quot;&amp;gt;&lt;/em&gt;&lt;/div&gt;
&lt;div&gt;&lt;em&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;item_number&amp;gt;My&amp;nbsp;Part&amp;lt;/item_number&amp;gt;&lt;/em&gt;&lt;/div&gt;
&lt;div&gt;&lt;em&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;/Item&amp;gt;&lt;/em&gt;&lt;/div&gt;
&lt;div&gt;&lt;em&gt;&amp;lt;/AML&amp;gt;&lt;/em&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Result:&lt;/p&gt;
&lt;div&gt;
&lt;div&gt;&lt;em&gt;&amp;lt;Item&amp;nbsp;type=&amp;quot;Part&amp;quot;&amp;nbsp;typeId=&amp;quot;4F1AC04A2B484F3ABA4E20DB63808A88&amp;quot;&amp;nbsp;id=&amp;quot;5AC23F6FFDCF4F7C83A88DC04CBD50A0&amp;quot;&amp;gt;&lt;/em&gt;&lt;/div&gt;
&lt;div&gt;&lt;em&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;created_by_id&amp;nbsp;&lt;strong&gt;keyed_name=&amp;quot;Terry&amp;nbsp;Adams&amp;quot;&lt;/strong&gt;&amp;nbsp;type=&amp;quot;User&amp;quot;&amp;gt;18DF23B3851D4C9FA1B96E9CF1F585A8&amp;lt;/created_by_id&amp;gt;&lt;/em&gt;&lt;/div&gt;
&lt;div&gt;&lt;em&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;id&amp;nbsp;keyed_name=&amp;quot;My&amp;nbsp;Part&amp;quot;&amp;nbsp;type=&amp;quot;Part&amp;quot;&amp;gt;5AC23F6FFDCF4F7C83A88DC04CBD50A0&amp;lt;/id&amp;gt;&lt;/em&gt;&lt;/div&gt;
&lt;div&gt;&lt;em&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;itemtype&amp;gt;4F1AC04A2B484F3ABA4E20DB63808A88&amp;lt;/itemtype&amp;gt;&lt;/em&gt;&lt;/div&gt;
&lt;div&gt;&lt;em&gt;&amp;lt;/Item&amp;gt;&lt;/em&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;As we can see from the results, it looks like we can access the name of the creator through the&amp;nbsp;&lt;em&gt;keyed_name&lt;/em&gt; attribute of the&amp;nbsp;&lt;em&gt;created_by_id&lt;/em&gt; property. &lt;a href="https://www.w3schools.com/xml/xpath_syntax.asp"&gt;Using XPath&lt;/a&gt;, you can get the value of an attribute by using an expression that ends with&amp;nbsp;&lt;em&gt;/@attribute_name&lt;/em&gt;. In this case, if you can access the ID of the creator using &lt;em&gt;${created_by_id}&lt;/em&gt;, you should be able to access the name of the creator using &lt;strong&gt;&lt;em&gt;${created_by_id/@keyed_name}&lt;/em&gt;&lt;/strong&gt;.&lt;/p&gt;
&lt;hr /&gt;
&lt;p&gt;Chris&lt;/p&gt;
&lt;p&gt;Christopher GIllis&lt;/p&gt;
&lt;p&gt;Aras Labs Software Engineer&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>