question

Vothan Salomão avatar image
0 Likes"
Vothan Salomão asked Jason Lightfoot answered

How to link an item from the Combobox to other Edits in the Dashboard?

Hello, can anyone help me with a question about the Dashboard? I have a Global Table with 3 columns, where the first one is the names of all tables, the second is a column of on and off tables, with value 1 the table is on and with value 0 the table is off and in the third column, there is the type of table, whether it is an output table, input or reversible, as you can see in the image.


I was able to create using the Gui, a combobox that has all the tables and when clicking on the chosen table, it already shows in boxes 2 and 3 if it is on or off and if it is output, input or reversible, as in the example in the Gif. I would like to do this same procedure in the Dashboard. I created a reference code. But it is not working, I would like to know what is wrong and how could I be doing this.

tabela.png





codigo.png

FlexSim 23.0.5
dashboardscomboboxmodel input
tabela.png (43.3 KiB)
codigo.png (81.3 KiB)
· 1
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Jason Lightfoot avatar image Jason Lightfoot ♦♦ commented ·
If you already have the working GUI you can try using the GUI Class dashboard widget and link to that.
0 Likes 0 ·

1 Answer

Jason Lightfoot avatar image
1 Like"
Jason Lightfoot answered

The syntax to set a combo widget is this:

treenode dashcombo=getdashboardcontrol("combo");
set(itemcurrent(dashcombo),2);   //2 is the second item in the combo list
comborefresh(dashcombo);
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.