<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent posts to Local Variable of Visu accessible from "Execute ST code"</title><link href="https://forge.codesys.com/forge/talk/Visualization/thread/93092f71d0/" rel="alternate"/><link href="https://forge.codesys.com/forge/talk/Visualization/thread/93092f71d0/feed.atom" rel="self"/><id>https://forge.codesys.com/forge/talk/Visualization/thread/93092f71d0/</id><updated>2023-07-19T08:47:38.181000Z</updated><subtitle>Recent posts to Local Variable of Visu accessible from "Execute ST code"</subtitle><entry><title>Local Variable of Visu accessible from "Execute ST code"</title><link href="https://forge.codesys.com/forge/talk/Visualization/thread/93092f71d0/?limit=25#564b/0d15" rel="alternate"/><published>2023-07-19T08:47:38.181000Z</published><updated>2023-07-19T08:47:38.181000Z</updated><author><name>macros8</name><uri>https://forge.codesys.com/u/macros8/</uri></author><id>https://forge.codesys.com96c98c1cd05af76d205f67661bba8f304d8f70c0</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hi Fless,&lt;/p&gt;
&lt;p&gt;may I have a couple additional question to local vars?&lt;/p&gt;
&lt;p&gt;1) Is it possible to monitor value of them during Login?&lt;br/&gt;
2) Are they initialized always as soon as the visualisation is opened/closed? &lt;br/&gt;
(I struggle a little bit how to realized initialization of some values when the screen is opened/closed -&amp;gt; usually in HMI sw there are scripts corresponding to those events but I cannot find easy way in Codesys visu for that -&amp;gt; only create PLC program to handle that which is not as easy;)).&lt;/p&gt;
&lt;p&gt;Btw. -&amp;gt; your hint works perfectly.&lt;/p&gt;
&lt;p&gt;Thanks a lot.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Local Variable of Visu accessible from "Execute ST code"</title><link href="https://forge.codesys.com/forge/talk/Visualization/thread/93092f71d0/?limit=25#564b/b88e" rel="alternate"/><published>2023-07-19T06:21:33.768000Z</published><updated>2023-07-19T06:21:33.768000Z</updated><author><name>macros8</name><uri>https://forge.codesys.com/u/macros8/</uri></author><id>https://forge.codesys.comfb3eed6e9295f286b2f9a7477d62055079ff3994</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hi Fless,&lt;/p&gt;
&lt;p&gt;awesome, I believed it´s somehow possible.&lt;/p&gt;
&lt;p&gt;Thanks a lot.&lt;br/&gt;
M.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Local Variable of Visu accessible from "Execute ST code"</title><link href="https://forge.codesys.com/forge/talk/Visualization/thread/93092f71d0/?limit=25#564b" rel="alternate"/><published>2023-07-18T21:39:05.657000Z</published><updated>2023-07-18T21:39:05.657000Z</updated><author><name>Fless</name><uri>https://forge.codesys.com/u/fless/</uri></author><id>https://forge.codesys.com64a5814cfac32f06bfa20815a61c3de840a4546c</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;you can use local variables in the ST code action&lt;br/&gt;
it's just not shown in the input assistant.&lt;/p&gt;
&lt;p&gt;as workaround use&lt;/p&gt;
&lt;div class="codehilite"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class="err"&gt;THIS^.iPassFirstTry&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;

&lt;/div&gt;</summary></entry><entry><title>Local Variable of Visu accessible from "Execute ST code"</title><link href="https://forge.codesys.com/forge/talk/Visualization/thread/93092f71d0/?limit=25#72c2" rel="alternate"/><published>2023-07-18T08:04:15.380000Z</published><updated>2023-07-18T08:04:15.380000Z</updated><author><name>macros8</name><uri>https://forge.codesys.com/u/macros8/</uri></author><id>https://forge.codesys.com63a7a6cb4e1707c1058f4369e950ff62cfa41cad</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hi, &lt;/p&gt;
&lt;p&gt;just up of the topic;)&lt;br/&gt;
Isn´t there any possibility of using local variables of screen in corresponding Input configuration event - Execute ST code? &lt;br/&gt;
It would be really helpful.&lt;/p&gt;
&lt;p&gt;Thanks a lot.&lt;br/&gt;
M.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Local Variable of Visu accessible from "Execute ST code"</title><link href="https://forge.codesys.com/forge/talk/Visualization/thread/93092f71d0/?limit=25#ab33" rel="alternate"/><published>2023-06-21T08:46:08.798000Z</published><updated>2023-06-21T08:46:08.798000Z</updated><author><name>macros8</name><uri>https://forge.codesys.com/u/macros8/</uri></author><id>https://forge.codesys.com81e41fe1a3868d0519a8ad0f03f13f6b4bf440c7</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I wanted to use local variables in my script related to event mouseclick.&lt;/p&gt;
&lt;p&gt;But I have found out that for Execute ST code those local variables are not visible (even in Input assistant).&lt;br/&gt;
The strange is that if I use function Write/Toggle variable those variables are available for use.&lt;/p&gt;
&lt;p&gt;Do you know if there is any chance to use there variable inside the script. It would be much easier for use and keep HMI part separated from PLC part.&lt;/p&gt;
&lt;p&gt;Thanks a lot.&lt;br/&gt;
Regards.&lt;/p&gt;&lt;/div&gt;</summary></entry></feed>