<?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>User notification from server methods</title><link>https://www.aras.com/community/f/development/5932/user-notification-from-server-methods</link><description>Hi, 
 I&amp;#39;m creating server method and populating a new Part structure (+ doing other thing in an method). And last thing from method I would like to send &amp;#39;on screen &amp;#39; summary/notification what happened to the user (like inn.newError(&amp;quot;Hi, this is what happened</description><dc:language>ja-JP</dc:language><generator>Telligent Community 12</generator><item><title>RE: User notification from server methods</title><link>https://www.aras.com/community/thread/2783?ContentTypeID=1</link><pubDate>Thu, 18 Apr 2019 11:51:30 GMT</pubDate><guid isPermaLink="false">916d3f7e-8ddc-42f8-8d45-380822f51406:775abbe9-4305-4a8f-a71e-92152b55cc50</guid><dc:creator>Meismart</dc:creator><description>&lt;p&gt;You could try this.getInnovator().newResult();&amp;nbsp;&lt;/p&gt;
&lt;p&gt;It won&amp;#39;t Alert the user but rather return a status to the caller. you can see this by running an action with the target set to Window.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: User notification from server methods</title><link>https://www.aras.com/community/thread/2765?ContentTypeID=1</link><pubDate>Mon, 15 Apr 2019 11:16:25 GMT</pubDate><guid isPermaLink="false">916d3f7e-8ddc-42f8-8d45-380822f51406:e87e22b5-e293-49cf-9aff-fdc8438892d0</guid><dc:creator>jukkatlehtinen</dc:creator><description>&lt;p&gt;Hi, not 100% what I was looking for - but thanks, this made it clear. And I think I will go for a email option.&lt;/p&gt;
&lt;p&gt;//Jukka.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: User notification from server methods</title><link>https://www.aras.com/community/thread/2760?ContentTypeID=1</link><pubDate>Wed, 10 Apr 2019 14:24:21 GMT</pubDate><guid isPermaLink="false">916d3f7e-8ddc-42f8-8d45-380822f51406:8a4a250a-1e3b-4b39-8a4d-54a023ddadcd</guid><dc:creator>Christopher Gillis</dc:creator><description>&lt;p&gt;Hi Jukka,&lt;/p&gt;
&lt;p&gt;This is generally not possible as server methods are intended to run separate from the client. There are a couple built-in alternatives to get a notification to the user however.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Send an email to the user
&lt;ul&gt;
&lt;li&gt;Sample code for this can be found in the &lt;a href="/en/support/documentation/11-0-sp12"&gt;Programmer&amp;#39;s Guide&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Call your server method from a client method
&lt;ul&gt;
&lt;li&gt;This is a good choice if your server method is running from an Action instead of a Server Event&lt;/li&gt;
&lt;li&gt;You can run your server method by using &lt;em&gt;aras.applyMethod(YOUR_METHOD_NAME, YOUR_METHOD_BODY);&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;em&gt;&lt;/em&gt;Notifications to the user can be thrown using standard browser functions (&amp;nbsp;&lt;em&gt;alert(&amp;quot;This is what happened&amp;quot;);&amp;nbsp;&lt;/em&gt;) or Aras functions (&amp;nbsp;&lt;em&gt;aras.AlertSuccess(&amp;quot;This is what happened&amp;quot;);&amp;nbsp;&lt;/em&gt;)&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Create a new&amp;nbsp;&lt;strong&gt;Notification Message&lt;/strong&gt; item
&lt;ul&gt;
&lt;li&gt;Notification Messages are typically used to alert users of things like server maintenance, but you may be able to utilize them for your use case as well&lt;/li&gt;
&lt;li&gt;You can find these items under&amp;nbsp;&lt;strong&gt;TOC &amp;gt; Administration &amp;gt; Notification &amp;gt; Notification Message&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;/strong&gt;Aras will periodically poll for new notification messages to display to the user&lt;/li&gt;
&lt;li&gt;This interval for this polling can be configured by changing the value of the&amp;nbsp;&lt;strong&gt;MessageCheckInterval&lt;/strong&gt; variable item&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&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>