question

Enrique Elizaga avatar image
0 Likes"
Enrique Elizaga asked Borja Lorenzo commented

Anchor my custom GUI to the tools?

Can I make my custom GUI to be anchored with my tools in the tab control (next to view menu) as shown in picture...

FlexSim 18.2.2
guicustom toolbox
toolbox.jpg (49.1 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.

tannerp avatar image tannerp commented ·

Could you give a little more information? Custom GUIs will show up automatically in your Toolbox as shown in the picture below:

0 Likes 0 ·
gui-example.png (9.7 KiB)

1 Answer

tannerp avatar image
5 Likes"
tannerp answered Borja Lorenzo commented
@Enrique Elizaga

In order to have a window that you can anchor (to some extent), I would suggest using a Dashboard as follows:

First, create or open your Custom GUI:

Then, open a dashboard and add a "GUI Class" object:

Then, while in edit mode, select the GUI Class object. In the Quick Properties, find the eyedropper tool next to "Link" and use it to sample your Custom GUI:

This will create a Custom GUI that will function as a Dashboard window.

Hopefully this helps! Feel free to comment back if you're looking for something different or need clarification.


custom-gui.png (58.6 KiB)
custom-gui-2.png (72.2 KiB)
custom-gui-3.png (108.1 KiB)
· 6
5 |100000

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

Enrique Elizaga avatar image Enrique Elizaga commented ·

This is a great workaround. That´s exactly what I´m going to do.

1 Like 1 ·
Borja Lorenzo avatar image Borja Lorenzo Enrique Elizaga commented ·

Hello @tanner.p
Thanks for your answerd. It was helpfully.

How could you access the configuration panel of the GUI inserted in the Dashboard as you explained, WITHOUT having to go to the toolbox and open the Graphical User Interfaces?

And
I would also like to know if it is possible to save this GUI as an object in the library or another solution to make this configuration reproducible in another environment.
How can I make this?

0 Likes 0 ·
Logan Gold avatar image Logan Gold ♦♦ Borja Lorenzo commented ·

Hey @Borja Lorenzo, the closest thing I've found is to replicate the code that is used when the GUI builder is opened through the Toolbox. This is done with an application command called "opengui":

applicationcommand("opengui", Model.find("/Tools/GUIs/GUI 1"));

The second parameter is just a reference to the GUI that you want to open with the GUI Builder, so you could probably put this code on a button in the Dashboard and reference the GUI Widget by its Control ID. And then you could reference the actual GUI the widget is linked to. You may even be able to put a button in the GUI to do something similar, but I haven't tested either of these options to know for sure.

You can add the GUI to a User/Custom Library by going through the GUI Builder's GUI Option menu and choosing "Assign GUI to User Library". Then you can save off the user library and load it into another model to be able to use the GUI in that model.

0 Likes 0 ·
Show more comments