<?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: How to add log in Expression/Validation ? in ThingWorx Developers</title>
    <link>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/623300#M38447</link>
    <description>&lt;P&gt;&lt;a href="https://www.ptcusercommunity.com/t5/user/viewprofilepage/user-id/183931"&gt;@slangley&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I want to check if the expression/validation is executed by adding the log like 'The expression xxx is being executed'&amp;nbsp; and also display the values of the input parameters in the log .&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;regards,&lt;/P&gt;
&lt;P&gt;sean&lt;/P&gt;</description>
    <pubDate>Thu, 22 Aug 2019 01:11:55 GMT</pubDate>
    <dc:creator>seanccc</dc:creator>
    <dc:date>2019-08-22T01:11:55Z</dc:date>
    <item>
      <title>How to add log in Expression/Validation ?</title>
      <link>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/622723#M38336</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'd like to add some logs to expression and validation, I tried console.log() and logger.debug() , but both of them don't work.&amp;nbsp; &amp;nbsp;&lt;/P&gt;
&lt;P&gt;How should I add the logs&amp;nbsp; ?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Sean&lt;/P&gt;</description>
      <pubDate>Mon, 19 Aug 2019 03:28:10 GMT</pubDate>
      <guid>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/622723#M38336</guid>
      <dc:creator>seanccc</dc:creator>
      <dc:date>2019-08-19T03:28:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to add log in Expression/Validation ?</title>
      <link>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/623268#M38443</link>
      <description>&lt;P&gt;Hi &lt;a href="https://www.ptcusercommunity.com/t5/user/viewprofilepage/user-id/299300"&gt;@seanccc&lt;/a&gt;.&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;Can you provide more information regarding your use case?&amp;nbsp; What do you need to capture?&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;Regards.&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;--Sharon&lt;/P&gt;</description>
      <pubDate>Wed, 21 Aug 2019 19:54:17 GMT</pubDate>
      <guid>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/623268#M38443</guid>
      <dc:creator>slangley</dc:creator>
      <dc:date>2019-08-21T19:54:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to add log in Expression/Validation ?</title>
      <link>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/623300#M38447</link>
      <description>&lt;P&gt;&lt;a href="https://www.ptcusercommunity.com/t5/user/viewprofilepage/user-id/183931"&gt;@slangley&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I want to check if the expression/validation is executed by adding the log like 'The expression xxx is being executed'&amp;nbsp; and also display the values of the input parameters in the log .&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;regards,&lt;/P&gt;
&lt;P&gt;sean&lt;/P&gt;</description>
      <pubDate>Thu, 22 Aug 2019 01:11:55 GMT</pubDate>
      <guid>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/623300#M38447</guid>
      <dc:creator>seanccc</dc:creator>
      <dc:date>2019-08-22T01:11:55Z</dc:date>
    </item>
    <item>
      <title>Re: How to add log in Expression/Validation ?</title>
      <link>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/623609#M38494</link>
      <description>&lt;P&gt;Hi &lt;a href="https://www.ptcusercommunity.com/t5/user/viewprofilepage/user-id/299300"&gt;@seanccc&lt;/a&gt;.&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;There isn't any logging built in today.&amp;nbsp; You could submit this as an idea on the &lt;A href="https://community.ptc.com/t5/ThingWorx-Ideas/idb-p/thingworxideas" target="_blank"&gt;Ideas&lt;/A&gt; board, which would allow others to vote on it.&amp;nbsp; With enough votes, Engineering would consider it for a future release.&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;As an alternative, you could feed the inputs and outputs to an external service which would be responsible for logging the needed information.&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;Regards.&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;--Sharon&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Aug 2019 13:39:54 GMT</pubDate>
      <guid>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/623609#M38494</guid>
      <dc:creator>slangley</dc:creator>
      <dc:date>2019-08-23T13:39:54Z</dc:date>
    </item>
    <item>
      <title>Re: How to add log in Expression/Validation ?</title>
      <link>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/623868#M38550</link>
      <description>&lt;P&gt;Hello Sean,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;console.log&lt;/EM&gt; works for me, logging correctly in Chrome DevTools. If you want to log on the server side, you can call the service &lt;EM&gt;ApplicationLog.Write&lt;/EM&gt; instead.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;BR /&gt;Constantine&lt;/P&gt;</description>
      <pubDate>Mon, 26 Aug 2019 11:10:09 GMT</pubDate>
      <guid>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/623868#M38550</guid>
      <dc:creator>Constantine</dc:creator>
      <dc:date>2019-08-26T11:10:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to add log in Expression/Validation ?</title>
      <link>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/624246#M38619</link>
      <description>&lt;P&gt;&lt;a href="https://www.ptcusercommunity.com/t5/user/viewprofilepage/user-id/304626"&gt;@Constantine&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;That's strange,&amp;nbsp;console.log didn't work for me.&amp;nbsp; I'll try it again to see if it can work.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 28 Aug 2019 12:22:41 GMT</pubDate>
      <guid>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/624246#M38619</guid>
      <dc:creator>seanccc</dc:creator>
      <dc:date>2019-08-28T12:22:41Z</dc:date>
    </item>
    <item>
      <title>Re: How to add log in Expression/Validation ?</title>
      <link>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/624274#M38632</link>
      <description>&lt;P&gt;Just tried it with 8.4, still works :) Here's an example.&lt;/P&gt;</description>
      <pubDate>Wed, 28 Aug 2019 13:36:30 GMT</pubDate>
      <guid>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/624274#M38632</guid>
      <dc:creator>Constantine</dc:creator>
      <dc:date>2019-08-28T13:36:30Z</dc:date>
    </item>
    <item>
      <title>Re: How to add log in Expression/Validation ?</title>
      <link>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/624282#M38636</link>
      <description>&lt;P&gt;Hi seanccc,&lt;/P&gt;
&lt;P&gt;Maybe try the&amp;nbsp; TW.log client logger.&lt;/P&gt;
&lt;P&gt;You can find an example in &lt;A href="https://www.ptc.com/en/support/article?n=CS306951" target="_blank" rel="noopener"&gt;https://www.ptc.com/en/support/article?n=CS306951&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;The output will show in the Mashup Console (ctrl+alt+F9)&lt;/P&gt;</description>
      <pubDate>Wed, 28 Aug 2019 14:16:00 GMT</pubDate>
      <guid>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/624282#M38636</guid>
      <dc:creator>smainente</dc:creator>
      <dc:date>2019-08-28T14:16:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to add log in Expression/Validation ?</title>
      <link>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/624288#M38637</link>
      <description>&lt;P&gt;&lt;a href="https://www.ptcusercommunity.com/t5/user/viewprofilepage/user-id/304626"&gt;@Constantine&lt;/a&gt;&amp;nbsp;,&amp;nbsp;&lt;a href="https://www.ptcusercommunity.com/t5/user/viewprofilepage/user-id/56171"&gt;@smainente&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Both of your approaches work !&amp;nbsp; Thank you.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Sean&lt;/P&gt;</description>
      <pubDate>Wed, 28 Aug 2019 14:40:25 GMT</pubDate>
      <guid>https://www.ptcusercommunity.com/t5/ThingWorx-Developers/How-to-add-log-in-Expression-Validation/m-p/624288#M38637</guid>
      <dc:creator>seanccc</dc:creator>
      <dc:date>2019-08-28T14:40:25Z</dc:date>
    </item>
  </channel>
</rss>

