EcoStruxure Geo SCADA Expert Forum
Schneider Electric support forum about installation, configuration, integration and troubleshooting of EcoStruxure Geo SCADA Expert (ClearSCADA, ViewX, WebX).
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-01-24 12:11 PM . Last Modified: 2023-05-03 12:18 AM
I am working on getting a mimic animation to work the way I want it to. I am trying to use a Metadata field that is referencing another point to change the visibility of a text box, and when I call that Metadata field, the result returned is the ID of the point listed in the Metadata field instead of the FullName. Is there any way around getting the ID instead of the FullName?
Long version, I have a Valve Mimic that is heavily used. The point "Valve Position" is configured to the valve mimic on many screens, and my valve symbol has an animation for a box to represent the valve is in "Manual", which is another point. I'm trying to get the Valve Mimic to have a yellow box with an M inside it if the Manual point .CurrentStateDesc contains 'Man', without needing to go to every screen and configure another point to the valve mimic.
Using a Metadata field configured as a String instead of Reference sort of works, but the STRING has to be manually entered in each instance of a template (which I'm trying to avoid the extra steps), and a Reference data field automatically updates to the correct point, but only returns the point ID.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-01-27 01:55 PM
Sorry, I probably should have read the full issue that you have.
My recommendation here is to have an entire mimic 'symbol' (which takes no parameters) within the template.
Then you drag and drop the template instance version of the symbol onto each mimic as applicable.
This template instance version would also be where the 'shared with other embedded mimics' linkage would be broken.
Whilst the idea of having a single standard mimic which is dragged and dropped on each screen, and then configured for the appropriate device instance sounds good (only 1 DB object shared for all devices), as you're learning, when you make enhancements to this that require another parameter then it's painful work to add these in.
Whilst having 1 DB object (mimic) per Template Instance (since it's defined in the Template) does add lots of extra DB objects over time, the impact of these is typically very small.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-01-27 12:06 AM
There is a terribly bad way to do something like what you're after...
NOTE: AVOID USING THIS IN A PRODUCTION DATABASE... HERE LAY DRAGONS.
So there is a hidden little trick in the expression world, where you can perform an SQL Query as 'a tag'.
Then you can nest this as an indirect tag reference and get something similar.
So, assume that you have a Metadata field called 'ReferencedObject' which is of Reference type.
Then you could do the following
['?SELECT FullName FROM CDBObject WHERE ID = ' + Str(".Overview.ReferencedObject")]
To get the FullName for the object based upon the ID field for it.
Obviously if you want to start doing additional things, like animating a value based upon the value of the point pointed to by the reference field, then this is possible also.
Something like
['?SELECT CurrentValueAsVariant FROM CDBPoint WHERE ID = ' + Str(".Overview.ReferencedObject")]
But you have to keep in mind that this is performing a query, plus all the database transactions for this, each time any of the referenced objects has an Update triggered for it. So it will lead to bad database performance.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-01-27 06:29 AM
So it sounds like the better option is one of a few possibilities that require me to go through and edit every instance of a template.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-01-27 01:55 PM
Sorry, I probably should have read the full issue that you have.
My recommendation here is to have an entire mimic 'symbol' (which takes no parameters) within the template.
Then you drag and drop the template instance version of the symbol onto each mimic as applicable.
This template instance version would also be where the 'shared with other embedded mimics' linkage would be broken.
Whilst the idea of having a single standard mimic which is dragged and dropped on each screen, and then configured for the appropriate device instance sounds good (only 1 DB object shared for all devices), as you're learning, when you make enhancements to this that require another parameter then it's painful work to add these in.
Whilst having 1 DB object (mimic) per Template Instance (since it's defined in the Template) does add lots of extra DB objects over time, the impact of these is typically very small.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-01-27 07:08 PM
Your option 2 may not be as bad as you think. Use the Bulk Edit tool to get the Metadata fields, exported to an excel file then you can update them. If the fullname of the object that contains the Metadata field is similar to the actual full name you need, you could copy those and then do a quick edit of them.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-01-28 05:40 AM
I had come up with a similar plan for option 2 late yesterday afternoon. I am considering using a ST or FBD within the template to fill in my Metadata string field that can be executed manually or from another ST program that can query and located all of the logic programs of a particular name and execute them all.
Fortunately, my Valve Position and Auto - Manual CMD are in the same group template, so either my idea above our Geoff's idea would be fairly easy to complete.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-01-28 05:55 AM
A new option has entered the thread!
Option 4 is something I've done in the past where instead of using a reference field, convert it to a link field. Links will provide the reference and a full objectlink to the object. You can use the object in an animation if you do something super clever and not recommended on a base object, but on the top layer of something it seems fine in my experience.
If you're familiar with object links, you know that it'll return something like SCX:///objecttype/Somegroup.somepointhere
In an animation, to get the object you want, you can use ELEMENT(1,'/',linkmetadatahere,1) to have it return the full path to the object.
If you do what most frown upon and use an indirect animation, you could then do:
[ELEMENT(1,'/',linkmetadatahere,1) + '.thepropertyyouneed']
Use of indirect animations should be limited, as you may already know. It's a touchy subject and you'll find a lot of content around them in these forums.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-01-28 05:57 AM
I should probably have made the following point a littler more clear:
If you use this method, be sure to only do it on the top layer of something. An indirect animation on the base level of an embedded mimic will cause significant performance issues if not implemented properly.
Link copied. Please paste this link to share this article on your social media post.
Create your free account or log in to subscribe to the board - and gain access to more than 10,000+ support articles along with insights from experts and peers.