question

Yifei Wang avatar image
1 Like"
Yifei Wang asked Brandon Peterson edited

How to change settings for all selected items all in once?

Hi,

I would like add some codes on OnReset Code Editor for all selected Racks. Since there are many Racks, it would be tedious to add the same thing one by one. I know how to add labels to all selected Racks in one time. But, I am confused on whether there is a way to add codes in Triggers all in once as well. Thanks!

FlexSim 16.0.1
rackselected objectstriggeruser command
5 |100000

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

Jeff Nordgren avatar image
3 Likes"
Jeff Nordgren answered Yifei Wang commented

Here is pretty much the same answer as Sam but with all the video in one screen that is easier to see.

Change the Reset Trigger code on one of the racks. Then select all the other racks to copy that code to. Using the Edit Selected Objects screen, selected from the View>Edit Selected Objects menu option, go to the field with the down symbol (just below the All Variables button) and press the down arrow. Find the resettrigger option and press the "Copy" button next to the field. You can then open one of the other racks to verify that the code has been copied.


· 2
5 |100000

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

Mischa Spelt avatar image Mischa Spelt commented ·

Additional tip: put the reset code in a User Command and call that from your reset triggers, i.e. make the on reset look like

OnRackReset(current);

That way, you only have to do this copy operation once and if you decide you need to change the code afterwards you can do it in a single place.

1 Like 1 ·
Yifei Wang avatar image Yifei Wang commented ·

thanks

0 Likes 0 ·
Sam Stubbs avatar image
2 Likes"
Sam Stubbs answered Yifei Wang commented

So you can do this by making the change you want on one of the racks, and then you can Shift+click and drag select the other racks. Then go to the View dropdown menu at the top and select Edit Selected Objects. Over on the right you'll see all the options you cans change. So now left click the Rack that has the trigger you want, and under the "Copy From Highlighted" there is a dropdown option right below where it says "All Variables". From that dropdown you can select the trigger you want. In this case, the "resettrigger". You can then deselect the objects by shift clicking in a blank space in your project.


selectitem1.gif (1.2 MiB)
selectitem2.gif (398.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.

Yifei Wang avatar image Yifei Wang commented ·

thanks

0 Likes 0 ·