Hi Everyone,
how can I solve issue with custom script to read a value DVSYS.Read('TASCHENRECHNER/INPUT_VALUE.CV') from control module. This script is customized on click button of the faceplate. It delivers undefined value to back faceplate and after clicking several times it shows right value.
Thanks
Andre Dicaire
You should by default use DLSYS object functions in DeltaV Live (like Andre said). Per Graphics Studio Help (F1 help) :
If you are reading a value where the module will always exist (ie not a phase), you can use DLSYS[<DeltaV Live parameter path string>] to get the information. As an example here is a text box looking at DLSYS["BJM_TEST/INPUT.CV"] (a custom module I created):
Demo
Andre Dicaire I think that the .value ending for the DLSYS.Read() function is dot notation access point for TypeScript.
There are other "dot" (.) properties that can be observed via the F12 debugger on a graphic. Note: you need to enable debugger on a per graphic basis.
The debug console isn't always 1-to-1 w/ scripts that can be created in Live but usually it's pretty close. Cheers!
Ben Merryman
In reply to Ben Merryman:
In reply to Matt Stoner:
Hi Matt, I am trying to read the value and update the Label of the text. Sometimes I get the text "undeifined". This is like:
Dsp.Ergebnis.Label = (await DLSYS.Read('TASCHENRECHNER/OPERAND1.CV').Value) + " * " + (await DLSYS.Read('TASCHENRECHNER/INPUT_VALUE.CV').Value) + " % ".
If the display stays opened for a long time, I dont get the text "undeifined". But if the display opened for a first time, it needs a little time to return normal values in the text, or I need to make some operations to update the text with pressing buttons.