/**Custom Code - fill pallet on creation*/ Object current = ownerobject(c); Object item = param(1); int rownumber = param(2); //row number of the schedule/sequence table Object cylinderRoot = createcopy(model().find("/Tools/FlowItemBin/Cylinder/Cylinder"),model(),1,0,0,0); // copy a cylinder item from the flowitem bin into the model cylinderRoot.size = Vec3(0.15,0.15,0.3); // set size of the cylinder for(int index = 1; index < current.palletContent; index++){ // label value of "palletContent" does what it is called insertcopy(cylinderRoot,item); // copy the cylinder into the pallet } moveobject(cylinderRoot,item); // move the first cylinder copy into pallet