How can I get the values (number of Bays, Levels, and slots) set in the Dimensions of the storage?
How can I get the values (number of Bays, Levels, and slots) set in the Dimensions of the storage?
You can access the bays directly from the storage object.
Storage.Object Rack = <Insert reference to object here>; int BayNum = Rack.bays.length;
As each bay might have a different number of levels, you have to define for which bay you want to access the levels.
Storage.Bay CurrentBay = Rack.bays[<Index of the bay>]; int LevelNum = CurrentBay.levels.length;
In the same way, the slots are accessed through each level.
Storage.Level CurrentLevel = CurrentBay.levels[<index of the level>]; int SlotNum = CurrentLevel.slots.length;
For an example of how this is used, you can look at the code of the default options for the "Slot Assignment Strategy" of a rack or floor storage.
16 People are following this question.
FlexSim can help you understand and improve any system or process. Transform your existing data into accurate predictions.
FlexSim is a fully 3D simulation software environment. FlexSim can be used to simulate any process in any industry.
FlexSim®, FlexSim Healthcare™, Problem Solved.®, the FlexSim logo, the FlexSim X-mark, and the FlexSim Healthcare logo with stylized Caduceus mark are trademarks of FlexSim Software Products, Inc. All rights reserved.
Privacy | Do not sell or share my personal information | Cookie preferences | Report noncompliance | Terms of use | Legal | © Autodesk Inc. All rights reserved