<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent posts to Copying 2 byte word to output</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/536aefd361/" rel="alternate"/><link href="https://forge.codesys.com/forge/talk/Engineering/thread/536aefd361/feed.atom" rel="self"/><id>https://forge.codesys.com/forge/talk/Engineering/thread/536aefd361/</id><updated>2025-03-03T19:58:01.975000Z</updated><subtitle>Recent posts to Copying 2 byte word to output</subtitle><entry><title>Copying 2 byte word to output</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/536aefd361/?limit=25#102b" rel="alternate"/><published>2025-03-03T19:58:01.975000Z</published><updated>2025-03-03T19:58:01.975000Z</updated><author><name>peterkcontrols</name><uri>https://forge.codesys.com/u/peterkcontrols/</uri></author><id>https://forge.codesys.com5559bb687a630ddf3afee0392a09b40424b9257f</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hello. I am using codesys 3.5. I would like to know if it is possible to set a variable to an output without declaring in. I have defined a STRUCT and within this struct I have a Struct for inputs called I and a struct for outputs called O. &lt;/p&gt;
&lt;p&gt;I have declared a variable of the type of this Struct, I would like to set or alias the value in this variable to an input/output value of an IO block that has a module on the ethernet tree. &lt;/p&gt;
&lt;p&gt;Is it possible to copy  the contents of %IW0 -&amp;gt; STRUCT.I ? The size of both of these is 2 bytes. &lt;br/&gt;
I understand that I can declare a variable with the input like Input01 AT %IX0.0 : BOOL; &lt;br/&gt;
However how can I make STRUCT.I.D00 AT %IX0.0?&lt;/p&gt;
&lt;p&gt;Is this possible? &lt;/p&gt;
&lt;p&gt;Thanks&lt;/p&gt;&lt;/div&gt;</summary></entry></feed>