The value of the Zenon variable is not changed from C # code.
Hello,
I'm trying to set the value of the Zenon variable in C # code in the following way:
zVariable.SetValue(newValue, Constants.STATE_SPONT, (int)InternalHelpers.TimeConversion.SystemToZenOn(dt), 0);
_utils.AddLine($"Variable: {zVariable.Name} Wert: {newValue} Datum: {dt} in der Funktion {MethodName} geschrieben");
The Zenon variable name is formed like this:
https://forum.copadata.com/showthread.php?9376-assign-variables-in-structured-data-type
In the Zenon project, the variable is in a Real format, in C # in a Double.
Everything is displayed correctly in the log file, but the new value is not assigned into the Zenon variable .
Which Zenon settings should I pay attention to?
Thank you in advance.
This is a migrated post! Originally posted on 14.06.2021 by user genakust. Please be aware that information can be outdated.