<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Point Value Link Trigged by button or page change]]></title><description><![CDATA[<p dir="auto">Hi,<br />
I am wanting to set it up a button so when pressed it opens up a page and Transfers the current value of one point value to a second one.</p>
<p dir="auto">This is what i've got so far but it doesn't appear to work</p>
<pre><code>&lt;ma-get-point-value point-xid="Visitor-Number-Selected" point="Vist_Num"&gt;&lt;/ma-get-point-value&gt;
&lt;ma-button id="New-Vist" style="position: absolute; left: 1217.99px; top: 1002.03px; z-index: 4;" raised="true" ui-sref="scada.vistorSetupPage" label="New Visitor" ng-click="Vist_Num.setValue("Visitor-Number-Selected-Script")" =""=""&gt;&lt;/ma-button&gt;
</code></pre>
<p dir="auto">Thanks in advance<br />
BIlly</p>
]]></description><link>https://forum.mango-os.com/topic/3198/point-value-link-trigged-by-button-or-page-change</link><generator>RSS for Node</generator><lastBuildDate>Sun, 07 Jun 2026 14:00:39 GMT</lastBuildDate><atom:link href="https://forum.mango-os.com/topic/3198.rss" rel="self" type="application/rss+xml"/><pubDate>Tue, 09 Jan 2018 23:07:47 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Point Value Link Trigged by button or page change on Tue, 16 Jan 2018 18:01:03 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/jared-wiltshire" aria-label="Profile: jared-wiltshire">@<bdi>jared-wiltshire</bdi></a><br />
Hi jared,<br />
Didn't realise i needed to add ".value" at the end i have now added it and the button now works as i wanted :) Thanks for you help<br />
Regards<br />
Billy</p>
]]></description><link>https://forum.mango-os.com/post/16919</link><guid isPermaLink="true">https://forum.mango-os.com/post/16919</guid><dc:creator><![CDATA[Bhanner]]></dc:creator><pubDate>Tue, 16 Jan 2018 18:01:03 GMT</pubDate></item><item><title><![CDATA[Reply to Point Value Link Trigged by button or page change on Tue, 16 Jan 2018 16:11:26 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/bhanner" aria-label="Profile: bhanner">@<bdi>bhanner</bdi></a> said in <a href="/post/16906">Point Value Link Trigged by button or page change</a>:</p>
<blockquote>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/jared-wiltshire" aria-label="Profile: jared-wiltshire">@<bdi>jared-wiltshire</bdi></a><br />
Hi jared,<br />
The code you gave me did work but it set the value of the first tag to 0 regardless of what the value of the second tag was</p>
<pre><code>&lt;ma-get-point-value point-xid="Visitor-Number-Selected" point="Vist_Num"&gt;&lt;/ma-get-point-value&gt;
&lt;ma-get-point-value point-xid="Visitor-Number-Selected-Script" point="Script"&gt;&lt;/ma-get-point-value&gt;
&lt;ma-button id="New-Vist" style="position: absolute; left: 1217.99px; top: 1002.03px; z-index: 4;" raised="true" label="New Visitor" ng-click="Vist_Num.setValue('Script'); $state.go('scada.vistorSetupPage')"&gt;&lt;/ma-button&gt;
</code></pre>
<p dir="auto">Can you see what i'm doing wrong?i'm a bit stumped if it won't work i have a way to make it work using scripts but i'd rather not use that</p>
</blockquote>
<p dir="auto">What I gave was an example which you would need to modify. Given the two points which you have included above I can make it more specific. Try this.</p>
<pre><code>&lt;ma-get-point-value point-xid="Visitor-Number-Selected" point="Vist_Num"&gt;&lt;/ma-get-point-value&gt;
&lt;ma-get-point-value point-xid="Visitor-Number-Selected-Script" point="Script"&gt;&lt;/ma-get-point-value&gt;
&lt;ma-button id="New-Vist" style="position: absolute; left: 1217.99px; top: 1002.03px; z-index: 4;" raised="true" label="New Visitor" ng-click="Vist_Num.setValue(Script.value); $state.go('scada.vistorSetupPage')"&gt;&lt;/ma-button&gt;
</code></pre>
<p dir="auto">You were setting the point to the string value 'Script'. I have modified it to set it to the point value. Note there are no single quotes and we access the point value using <code>.value</code></p>
]]></description><link>https://forum.mango-os.com/post/16909</link><guid isPermaLink="true">https://forum.mango-os.com/post/16909</guid><dc:creator><![CDATA[Jared Wiltshire]]></dc:creator><pubDate>Tue, 16 Jan 2018 16:11:26 GMT</pubDate></item><item><title><![CDATA[Reply to Point Value Link Trigged by button or page change on Tue, 16 Jan 2018 13:55:26 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/jared-wiltshire" aria-label="Profile: jared-wiltshire">@<bdi>jared-wiltshire</bdi></a><br />
Hi jared,<br />
The code you gave me did work but it set the value of the first tag to 0 regardless of what the value of the second tag was</p>
<pre><code>&lt;ma-get-point-value point-xid="Visitor-Number-Selected" point="Vist_Num"&gt;&lt;/ma-get-point-value&gt;
&lt;ma-get-point-value point-xid="Visitor-Number-Selected-Script" point="Script"&gt;&lt;/ma-get-point-value&gt;
&lt;ma-button id="New-Vist" style="position: absolute; left: 1217.99px; top: 1002.03px; z-index: 4;" raised="true" label="New Visitor" ng-click="Vist_Num.setValue('Script'); $state.go('scada.vistorSetupPage')"&gt;&lt;/ma-button&gt;
</code></pre>
<p dir="auto">Can you see what i'm doing wrong?i'm a bit stumped if it won't work i have a way to make it work using scripts but i'd rather not use that</p>
]]></description><link>https://forum.mango-os.com/post/16906</link><guid isPermaLink="true">https://forum.mango-os.com/post/16906</guid><dc:creator><![CDATA[Bhanner]]></dc:creator><pubDate>Tue, 16 Jan 2018 13:55:26 GMT</pubDate></item><item><title><![CDATA[Reply to Point Value Link Trigged by button or page change on Wed, 10 Jan 2018 16:56:24 GMT]]></title><description><![CDATA[<p dir="auto">Using <code>ui-sref</code> and <code>ng-click</code> together wont work correctly I suspect.</p>
<p dir="auto">Try this.</p>
<pre><code>&lt;ma-get-point-value point-xid="Visitor-Number-Selected" point="Vist_Num"&gt;&lt;/ma-get-point-value&gt;
&lt;ma-button id="New-Vist" style="position: absolute; left: 1217.99px; top: 1002.03px; z-index: 4;" raised="true" label="New Visitor" ng-click="Vist_Num.setValue(myOtherValue); $state.go('scada.vistorSetupPage')"&gt;&lt;/ma-button&gt;
</code></pre>
]]></description><link>https://forum.mango-os.com/post/16778</link><guid isPermaLink="true">https://forum.mango-os.com/post/16778</guid><dc:creator><![CDATA[Jared Wiltshire]]></dc:creator><pubDate>Wed, 10 Jan 2018 16:56:24 GMT</pubDate></item><item><title><![CDATA[Reply to Point Value Link Trigged by button or page change on Wed, 10 Jan 2018 16:49:07 GMT]]></title><description><![CDATA[<p dir="auto">Hi Billy,</p>
<p dir="auto">Looks like there are a couple issues,</p>
<ol>
<li>Your quotes in the ng-click item are all double quotes. You need to use one type of quotes inside the other, like, <code>ng-click="Vist_Num.setValue('Visitor-Number-Selected-Script')"</code></li>
<li>There is extra junk in your directive. The <code> =""=""</code> at the end is nothing but trouble.</li>
</ol>
]]></description><link>https://forum.mango-os.com/post/16777</link><guid isPermaLink="true">https://forum.mango-os.com/post/16777</guid><dc:creator><![CDATA[phildunlap]]></dc:creator><pubDate>Wed, 10 Jan 2018 16:49:07 GMT</pubDate></item></channel></rss>