General Discussions
editing copies of widgets VTScada have built

Apologies if this has been asked already. Can I copy one of VTScada's widgets to my own library and then make some changes?

Their runtime widget doesn't do exactly what I need but I'd like to use it as a starting point to save time.

Apologies if this has been asked already. Can I copy one of VTScada's widgets to my own library and then make some changes? Their runtime widget doesn't do exactly what I need but I'd like to use it as a starting point to save time.

Nope - can't do that because VT only provides the compiled version of the Widget - same thing we can do when creating our own OEMs. You can take existing Widgets and add to their functionality but you will have no access to the Widget source code.

Nope - can't do that because VT only provides the compiled version of the Widget - same thing we can do when creating our own OEMs. You can take existing Widgets and add to their functionality but you will have no access to the Widget source code.

You can use a built-in widget as a starting point if you want to add to that widget but not if you want to modify the widget. If you need something specific, then please reach out to me by email https://www.vtscada.com/contact-us/ and I can request the code to get you started.

You can use a built-in widget as a starting point if you want to add to that widget but not if you want to modify the widget. If you need something specific, then please reach out to me by email https://www.vtscada.com/contact-us/ and I can request the code to get you started.

Trihedral Engineering Ltd.

Thanks Dave. It's your "elapsed time" widget that I need to reproduce. I've got an expression that does what I need but it feels over-complicated to me.

It might feel over-complicated because I'm a new VTScada user and everything feels that way but it might feel over-complicated because I've made it that way by using the wrong functions.

If it tests OK seven hours from now when it rolls over to a full day I'll e-mail it & get your thoughts.

Thanks Dave. It's your "elapsed time" widget that I need to reproduce. I've got an expression that does what I need but it feels over-complicated to me. It might feel over-complicated because I'm a new VTScada user and everything feels that way but it might feel over-complicated because I've made it that way by using the wrong functions. If it tests OK seven hours from now when it rolls over to a full day I'll e-mail it & get your thoughts.

Found some problems during testing but I've solved them now. Just sent you my kludgey expression by e-mail. Looking forwards to your thoughts.

Found some problems during testing but I've solved them now. Just sent you my kludgey expression by e-mail. Looking forwards to your thoughts.

Hey Mike,

I just had a chance to check out your email and that strategy looks reasonable to me. Since you are just reformatting the value of a tag, you could always just work this directly into script code in a custom widget. This would allow you to make your expression much more flexible but what you have done works well.

The only thing I'd really suggest is to insert a few PickValid()'s in your code to ensure that your conditionals are always evaluated. ie:

IfThen(PickValid([runtime],0)>1,...);
Hey Mike, I just had a chance to check out your email and that strategy looks reasonable to me. Since you are just reformatting the value of a tag, you could always just work this directly into script code in a custom widget. This would allow you to make your expression much more flexible but what you have done works well. The only thing I'd really suggest is to insert a few PickValid()'s in your code to ensure that your conditionals are always evaluated. ie: ```` IfThen(PickValid([runtime],0)>1,...); ````

Trihedral Engineering Ltd.

Great. Will read up on PickValid(). Thanks for taking a look.

Great. Will read up on PickValid(). Thanks for taking a look.

No problem Mike,

Down the road, you may want to read up on scripting outside of the calculation tags by writing custom widgets and tools directly in the source files. You can start that journey here: https://www.vtscada.com/help/Content/Scripting/API/S_Welcome.htm?tocpath=Scripting%7C_____0

No problem Mike, Down the road, you may want to read up on scripting outside of the calculation tags by writing custom widgets and tools directly in the source files. You can start that journey here: https://www.vtscada.com/help/Content/Scripting/API/S_Welcome.htm?tocpath=Scripting%7C_____0

Trihedral Engineering Ltd.

Hey Mike,

I wanted to follow up with you as I had a similar question on here recently and put together a small expression to put in a text box which will convert an elapsed time (my example uses seconds) to a base 60 time format which does not reset the hours after 24 (HH:mm:ss). You can check that out here as it may help you improve your needs:

https://forum.trihedral.com/index.php?u=/topic/555/showing-time-data-from-tag#post-1658

Hey Mike, I wanted to follow up with you as I had a similar question on here recently and put together a small expression to put in a text box which will convert an elapsed time (my example uses seconds) to a base 60 time format which does not reset the hours after 24 (HH:mm:ss). You can check that out here as it may help you improve your needs: https://forum.trihedral.com/index.php?u=/topic/555/showing-time-data-from-tag#post-1658

Trihedral Engineering Ltd.

Thanks for following up Dave. Your thoughtfullness is appreciated & noted.

Thanks for following up Dave. Your thoughtfullness is appreciated & noted.
191
10
3
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft