In perspective, in the desigenr when you click “+” next to pens, for example in the power chart component,
A new item is added in the array with an object structure with default value.
Is there a way to create a new item in pens array by script, but without specify all the props in order some props take default values ?
No, not in any dynamic way. That automatic behavior is a function of the JSON editor, not the actual property structure. You’d have to hardcode your ‘default’ elements for each possible value you would want to insert.
thanks, it was a bit utopian
Maybe, but aren’t we all here because Ignition is a SCADA/HMI Utopia??!?
Sorry @PGriffith but I’m adding this to the wish list! maybe a system.perspective.addArrayElement is in our future…
I did hear they were working on adding custom ‘tooltips’ for properties. i suppose this is relativly similar as it also works with the json (atleast it does atm, no idea how they will implement it or when)