Hi,
Im searching oh ways to write all the available storage object in my model.
I use some object connected to all the rack in my model and put this code to the said object :
int loop = 0;
for(int rack = 1; rack<= current.outObjects.length; rack++ ){
for(int bay = 1; bay<= rackgetnrofbays(current.outObjects[rack]) ; bay++){
for(int lvl = 1; lvl <= rackgetnroflevels(current.outObjects[rack]); lvl++){
loop++;
Table("Pallet_Unloading").addRow(0,0);
Table("Pallet_Unloading")[Table("Pallet_Unloading").numRows][1] = current.outObjects[rack].name;
Table("Pallet_Unloading")[Table("Pallet_Unloading").numRows][2] = bay;
Table("Pallet_Unloading")[Table("Pallet_Unloading").numRows][3] = lvl;
}
}
}
}
I write to "Table Unloading", the problem is, I only want to write the storable storage, I believe this is possible using the attribut of rack isStorable = 1. And I try to add this code :
if(Model.find(current.outObjects[rack].name+">variables/bays/"+bay+"/levels/"+lvl+"/isStorable") = 1){}
It doesn't work because Im getting the node and not the value of the node (the int number 1 for "storable" and 0 "non storable). How can I get the value of this isStorable?
Thank you