Are multiple

I’m trying to logically/visually sort many parameters; is it acceptable practice to use multiple tags, each say with their own name as a category, rather than having every parameter under the one?

With of course multiple in each ‘group’.

Are there any repercussions I should know about in doing so?

Thanks!

Paul

I can’t think of any repercussions to doing that. I just tried it in my custom panel and it works fine.

EDIT: After talking it over with the creator of DB, he says that it is not a recommended practice, because the OGScript context only tracks and writes to one of the tags. So you could end up with data being missed. Put all your parameters in one tag.

You could organize them using their OIDs. So anything that has to do with “teams” could be prefixed with “teams_”.

#DashBoard

Great thanks!

On a side note, I feel like I would like to know a little more about structs/suboids. Is there one of your great example files that specifically demonstrates how (and more importantly why) you would use these?

Thanks!

#DashBoard

In the example panels (https://support.rossvideo.com/hc/en-us/community/posts/360065970252-Free-DashBoard-Example-Panels-for-Everyone), there is a folder called “Parameters”. In there there is one for Arrays, then StructuredParam, and then StructuredParamArray, which build up to making a table of information using a structured parameter that’s an array.

Structured parameters are great for holding a lot of data in one parameter and being able to loop through all that data, or display it all in one place. Imagine you want to have all the data about a sports team, including the first name and last name of each player, their jersey number.

If you have 20 players, you could create 60 different parameters to hold all this data. E.g. player1_fname, player2_fname, player3_fname, etc. Then you would have to put all 60 parameters on your panel to see all the data. Which is hard to do.

Then someone decided there should be 24 players instead of 20. You have to modify your panel and add 12 new parameters. It’s hard to maintain.

Instead you could use subparams in an structured parameter, and use an array of them to make a table. That way all your data is in one parameter. You can drop that parameter in your panel and see all the data. The array also means that you can have a variable amount of data.

Here is another one I just created for other reasons which creates a “RunDown” type of panel.

Cam1 Cam2 Cam3 Video XP Presenter Cam1 Cam2 Cam3 Video XP Presenter On 75% 50% 25% Off Cam1 Cam2 Cam3 Video XP Presenter Cam1 Cam2 Cam3 Video XP Presenter On 75% 50% 25% Off function recallSelected() { var selected = params.getValue("selection",0); params.setValue("program",0,params.getValue("recalls." + selected + ".program",0)); params.setValue("preview",0,params.getValue("recalls." + selected + ".preview",0)); params.setValue("lights",0,params.getValue("recalls." + selected + ".lights",0)); } /*! block id=1000,1001,1002 !*/ ogscript.reveal(("top_tab" + params.getValue('program', 0))); /*!! !!*/ /*!!6101c215138606f16f5a9822a3fa7f4e!!*/ /*! block id=1003,1004,1006 !*/ ogscript.reveal(("bottom_tab" + params.getValue('preview', 0))); /*!! !!*/ /*!!52213b66fa9f6daa8672408f5d51fb22!!*/ var temp = params.getValue("program",0); params.setValue("program", 0,params.getValue("preview",0)); params.setValue("preview", 0, temp);
30 selection

/! block id=1013,1014 !/
params.setValue(‘selection’, 0, 0);
/! block id=1018 !/
recallSelected()
/!!



!!
/
/!!7eefd051806073b2bf293e6122ecf696!!/


/! block id=1015 !/
params.setValue(‘selection’, 0, params.getValue(‘selection’, 0) + 1);
/! block id=1019 !/
recallSelected()
/!!


!!
/
/!!0295c511f0828a30bdf3c9539545594d!!/


/! block id=1016 !/
params.setValue(‘selection’, 0, params.getValue(‘selection’, 0) + -1);
/! block id=1020 !/
recallSelected()
/!!


!!
/
/!!5183bc7045d27eb7e44a2475d85c5cb8!!/



/! block id=1017 !/
recallSelected()
/!!

!!
/
/!!f3631071b9084b849eec34c59cdef151!!/



var newarray = new Array();
var index = params.getValue(“selection”,0);
if (index>0) {

// Recreate the array of values, with a new order.
var count = params.getElementCount(“recalls”);
for (var i=0; i < count; i++) {
if (i == index-1) {
newarray.push(params.getValue(“recalls”,index));
continue;
}
if (i == index) {
newarray.push(params.getValue(“recalls”,index-1));
continue;
}
newarray.push(params.getValue(“recalls”,i));

}

params.setAllValues(“recalls”, newarray);
params.setValue(“selection”,0,index-1);
}


var newarray = new Array();
var index = params.getValue(“selection”,0);

var count = params.getElementCount(“recalls”);
if (index<count-1) {
// Recreate the array with a new order.
for (var i=0; i < count; i++) {
if (i == index+1) {
newarray.push(params.getValue(“recalls”,index));
continue;
}
if (i == index) {
newarray.push(params.getValue(“recalls”,index+1));
continue;
}
newarray.push(params.getValue(“recalls”,i));

}

params.setAllValues(“recalls”, newarray);
params.setValue(“selection”,0,index+1);
}




var index = params.getValue(“selection”,0);

var newarray = new Array();
var count = params.getElementCount(“recalls”);
// recreate the array, but leave out the one that is selected.
for (var i=0; i < count; i++) {
if (i != index) {
newarray.push(params.getValue(“recalls”,i));
}
}

params.setAllValues(“recalls”, newarray);

var newrecall = { name: params.getValue("store_name",0), program: params.getValue("program",0), preview: params.getValue("preview",0), lights: params.getValue("lights",0), };

var count = params.getElementCount(“recalls”);
var p = params.getParam(“recalls”,0);
p.setValueAt(count, newrecall);

#DashBoard

Hi Ben, your rundown panel looking very well!

The fact that you can insert constraints with drop-menu choices in table rows is fantastic!

Wondering if ‘enter’ shortcut can be assigned to trigger ‘next’ button.

Also, if it possible to disable cell editing on table, but allow to change dropdown constraints (pretty sure script table is the answer).

#DashBoard

Pressing enter will change the selection. We could add a task to the selection parameter so that when it changes, it triggers the recalls.

#DashBoard

After talking it over with the creator of DB, he says that it is not a recommended practice to use multiple tag, because the OGScript context only tracks and writes to one of the tags. So you could end up with data being missed. Put all your parameters in one tag.

You could organize them using their OIDs. So anything that has to do with “teams” could be prefixed with “teams_”.

#DashBoard

Thank you, appreciate the quick follow-up before I moved them all!

And very grateful for the response re structured parameters, I will have a look at your example!

Would you be interested in taking a look at a panel I have built, for feedback on how it might be made more efficiently? I have a tab element that I want to replicate 9x, and if I do so how it is now (rather clunky) it will require large replications of parameters and I just know there’s a better way to store things! And I’d like to make the first ‘copy’ well before duplicating poor code.

#DashBoard

If you’re replicating a portion of you panel multiple times, you may be better to use widgets. I just made a series of tutorial videos for the Worship Production market. One of those is how to make widgets.

You can find those videos here: https://www.rossvideo.com/applications/house-of-worship/. Just scroll down to the “House of Worship U” section.

Widgets basically allow you to have “sub-panels” repeated over and over. Each widget has its own set of internal parameters.

#DashBoard