Thanks for the video - I'll pass this on to the product team, as the behavior appears to be inconsistent.
If you need an entry to return to its default values and you're already using JSON to build structs in your project, I'd suggest creating a method to explicitly reset the entry. This avoids relying on the stateless attribute to revert values, though it does mean handling the behavior in script instead.
Here is an example for an alternative method.
<abs contexttype="opengear" id="_top" keepalive="false">
<meta>
<api immediate="true">function defaultEntry0(obj){
params.setValue('quantel.channels', 0, obj);
ogscript.debug('defaulted top entry');
}</api>
<ogscript handles="onload" targetid="_top">var obj = {
"port": 0,
"name": "?",
"mode": "?"
};
defaultEntry0(obj)</ogscript>
<params>
<param access="1" constrainttype="STRUCT" name="Channels" oid="quantel.channels.template" stateless="true" type="STRUCT" widget="default">
<value>
<subparam access="0" constrainttype="INT_NULL" name="Port" precision="0" stateless="true" suboid="port" type="INT16" value="0" widget="default"/>
<subparam access="0" maxlength="-1" name="Name" stateless="true" suboid="name" type="STRING" value="?" widget="default"/>
<subparam access="0" maxlength="-1" name="Mode" stateless="true" suboid="mode" type="STRING" value="?" widget="default"/>
</value>
</param>
<param access="1" constrainttype="STRUCT" name="Channels" oid="quantel.channels" stateless="true" templateoid="quantel.channels.template" type="STRUCT_ARRAY" widget="default">
<value>
<subparam stateless="true" suboid="port" value="0"/>
<subparam stateless="true" suboid="name" value="?"/>
<subparam stateless="true" suboid="mode" value="?"/>
</value>
</param>
<param access="1" constrainttype="STRUCT" name="Channels" oid="quantel.channels" stateless="true" templateoid="quantel.channels.template" type="STRUCT_ARRAY" widget="default">
<value>
<subparam stateless="true" suboid="port" value="0"/>
<subparam stateless="true" suboid="name" value=""/>
<subparam stateless="true" suboid="mode" value="Idle"/>
</value>
<value>
<subparam suboid="port" value="1"/>
<subparam suboid="name" value=""/>
<subparam suboid="mode" value="Idle"/>
</value>
<value>
<subparam suboid="port" value="2"/>
<subparam suboid="name" value="QvdcpI 0"/>
<subparam suboid="mode" value="Cued"/>
</value>
<value>
<subparam suboid="port" value="3"/>
<subparam suboid="name" value="QvdcpI 1"/>
<subparam suboid="mode" value="Cued"/>
</value>
<value>
<subparam suboid="port" value="4"/>
<subparam suboid="name" value=""/>
<subparam suboid="mode" value="Idle"/>
</value>
<value>
<subparam suboid="port" value="5"/>
<subparam suboid="name" value="QvdcpI 2"/>
<subparam suboid="mode" value="Cued"/>
</value>
</param>
</params>
</meta>
<table bottom="0" left="0" right="0" top="0">
<tr>
<simplegrid cols="3" colspan="1" fill="both" rows="3" rowspan="1" weightx="1.0" weighty="1.0">
<param element="0" expand="true" oid="struct_apples" showlabel="false"/>
<param expand="true" oid="struct_apples.0.apples_persistant" showlabel="false"/>
<param expand="true" oid="struct_apples.0.apples_stateless" showlabel="false"/>
<button buttontype="push" name="Refresh">
<task tasktype="ogscript">ogscript.reload('_top');</task>
</button>
<param editable="false" expand="true" oid="apples_stateless" showlabel="false"/>
<param expand="true" oid="apples_persistant" showlabel="false"/>
<button buttontype="push" name="Change top entry">
<task tasktype="ogscript">var obj = {
"port": 99,
"name": "Device 99",
"mode": "active"
};
defaultEntry0(obj)</task>
</button>
<param expand="true" oid="port2" showlabel="false"/>
</simplegrid>
<dropspot colspan="1" fill="both" rowspan="1" weightx="1.0" weighty="1.0"/>
</tr>
<tr>
<param colspan="1" expand="true" fill="both" oid="quantel.channels" rowspan="1" showlabel="false" weightx="1.0" weighty="1.0"/>
<param colspan="1" expand="true" fill="both" oid="quantel.channels.template" rowspan="1" showlabel="false" weightx="1.0" weighty="1.0"/>
</tr>
</table>
</abs>
------------------------------
Richard Crutwell
Ross Video UK
------------------------------
Original Message:
Sent: 02-06-2026 06:27
From: Simon Liddicott
Subject: stateless STRUCT_ARRAY
Thanks for this.
I've tried that code in 9.16 and the stateless feature isn't consistent, I've been able to make the state change in the apples_stateless in the attached video.
My workflow is using external xml for panel data.
My default entry is:
<param access="1" constrainttype="STRUCT" name="Channels" oid="quantel.channels.template" stateless="true" type="STRUCT" widget="default"> <value> <subparam access="0" constrainttype="INT_NULL" name="Port" precision="0" stateless="true" suboid="port" type="INT16" value="0" widget="default"/> <subparam access="0" maxlength="-1" name="Name" stateless="true" suboid="name" type="STRING" value="?" widget="default"/> <subparam access="0" maxlength="-1" name="Mode" stateless="true" suboid="mode" type="STRING" value="?" widget="default"/> </value> </param> <param access="1" constrainttype="STRUCT" name="Channels" oid="quantel.channels" stateless="true" templateoid="quantel.channels.template" type="STRUCT_ARRAY" widget="default"> <value> <subparam stateless="true" suboid="port" value="0"/> <subparam stateless="true" suboid="name" value="?"/> <subparam stateless="true" suboid="mode" value="?"/> </value> </param>
I parse an external JSON file to populate the STRUCT_ARRAY, so ideally the array is empty on load.
What I get is all of the subparams get a saved state including the top entry with the explicit stateless:
<param access="1" constrainttype="STRUCT" name="Channels" oid="quantel.channels" stateless="true" templateoid="quantel.channels.template" type="STRUCT_ARRAY" widget="default"> <value> <subparam stateless="true" suboid="port" value="0"/> <subparam stateless="true" suboid="name" value=""/> <subparam stateless="true" suboid="mode" value="Idle"/> </value> <value> <subparam suboid="port" value="1"/> <subparam suboid="name" value=""/> <subparam suboid="mode" value="Idle"/> </value> <value> <subparam suboid="port" value="2"/> <subparam suboid="name" value="QvdcpI 0"/> <subparam suboid="mode" value="Cued"/> </value> <value> <subparam suboid="port" value="3"/> <subparam suboid="name" value="QvdcpI 1"/> <subparam suboid="mode" value="Cued"/> </value> <value> <subparam suboid="port" value="4"/> <subparam suboid="name" value=""/> <subparam suboid="mode" value="Idle"/> </value> <value> <subparam suboid="port" value="5"/> <subparam suboid="name" value="QvdcpI 2"/> <subparam suboid="mode" value="Cued"/> </value> </param>
------------------------------
Simon Liddicott
Systems Engineer
Original Message:
Sent: 02-06-2026 05:00
From: Richard Crutwell
Subject: stateless STRUCT_ARRAY
The stateless attribute applies at the parameter level, and since a struct is effectively an array of parameters, it isn't inherited by child parameters. Unfortunately, this means the attribute is not automatically passed down.
To get the desired behavior in Dashboard, you must explicitly set stateless="true" on each sub-parameter.
Here's an example
<abs contexttype="opengear" id="_top" keepalive="false"> <meta> <params> <param access="1" constrainttype="STRUCT" name="struct_apples" oid="struct_apples" templateoid="struct.template" type="STRUCT_ARRAY" widget="table"> <value> <subparam access="1" constrainttype="STRING_CHOICE" maxlength="0" name="apples_persistant" suboid="apples_persistant" type="STRING" value="Golden Delicious" widget="combo"> <constraint>Golden Delicious</constraint> <constraint>Bramburn</constraint> <constraint>Crab</constraint> <constraint>Pink Lady</constraint> </subparam> <subparam access="1" constrainttype="STRING_CHOICE" maxlength="0" name="apples_stateless" stateless="true" suboid="apples_stateless" type="STRING" value="Golden Delicious" widget="combo"> <constraint>Golden Delicious</constraint> <constraint>Bramburn</constraint> <constraint>Crab</constraint> <constraint>Pink Lady</constraint> </subparam> </value> </param> </params> </meta> <table bottom="0" left="0" right="0" top="0"> <tr> <simplegrid cols="3" colspan="1" fill="both" rows="3" rowspan="1" weightx="1.0" weighty="1.0"> <param element="0" expand="true" oid="struct_apples" showlabel="false"/> <param expand="true" oid="struct_apples.0.apples_persistant" showlabel="false"/> <param expand="true" oid="struct_apples.0.apples_stateless" showlabel="false"/> <button buttontype="push" name="Refresh"> <task tasktype="ogscript">ogscript.reload('_top');</task> </button> </simplegrid> <dropspot colspan="1" fill="both" rowspan="1" weightx="1.0" weighty="1.0"/> </tr> <tr> <dropspot colspan="1" fill="both" rowspan="1" weightx="1.0" weighty="1.0"/> <dropspot colspan="1" fill="both" rowspan="1" weightx="1.0" weighty="1.0"/> </tr> </table></abs>
------------------------------
Richard Crutwell
Ross Video UK
Original Message:
Sent: 02-03-2026 20:27
From: Simon Liddicott
Subject: stateless STRUCT_ARRAY
Hi
in DashBoard stateless="true" doesn't seem to work with type="STRUCT_ARRAY" parameters.
Is this known? Or how should I get it to work?
Thanks.
------------------------------
Simon Liddicott
Systems Engineer
------------------------------