Graemek25

File Copy for NX/NJ

6 posts in this topic

Hello,

I have used RSlogix5K for years and I am now creating NX/NJ PLC program.  Is there a similar command to 'COP', which can copy ALL the data from a structured variable to either another equivalent structured variable or to a data array of some kind - e.g. a byte array?  I thought the MemCopy command might do this but I believe it only handles arrays, not structured vars.

Many Thanks

Graeme

Share this post


Link to post
Share on other sites

MOVE will copy an entire structure. Just specify the parent tag.

 

If you want to put the structure in a byte array use ToAryByte

 

1 person likes this

Share this post


Link to post
Share on other sites

Thank you - makes sense now ;-)

Share this post


Link to post
Share on other sites

Since you mentioned Logix, I'll just add that Omron doesn't automatically convert anything. You must be mindful of your apples and oranges. :-)

They do have a lot of conversion instructions.

Share this post


Link to post
Share on other sites

The MOVE instruction now does indeed convert data types (only certain combinations where you don't lose resolution however).

 

MoveConvert.jpg.5b02284f7215db50c94c4f2d

2 people like this

Share this post


Link to post
Share on other sites
15 hours ago, Michael Walsh said:

The MOVE instruction now does indeed convert data types (only certain combinations where you don't lose resolution however).

Nice! Thanks for the update!

It's also nice you were able to post a picture!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now