Cancel
Showing results for 
Search instead for 
Did you mean: 

Cannot Access the MUs in Z dim of Transporter with for loop ?

I am trying to unload the transporter using the for loop method. the problem is when I increase the z dim, it does not work but if i give the value in y and y dim of transporter and keep the z dim as 1, it works.

I am not understanding this behaviour.

Why this happens? anyone have any clue how to get rid of this?

4 REPLIES

Re: Cannot Access the MUs in Z dim of Transporter with for loop ?

Siemens Phenom Siemens Phenom
Siemens Phenom

Hello,

 

could you post your model or the code of your method?

Kind regards,

Igor
------------------------------------------------------------------------------------------------------
Did you like the answer? Then click the Thumbs Up button.
Did the answer solve your problem? Then accept the answer as solution


Re: Cannot Access the MUs in Z dim of Transporter with for loop ?

Hallo Igorkunjavskij, 

 

Please find the method below in the pic

Re: Cannot Access the MUs in Z dim of Transporter with for loop ?

Gears Esteemed Contributor Gears Esteemed Contributor
Gears Esteemed Contributor
@.cont returns everytime the same MU, the single MUs you can access with @.MU, if you move one MU the index will change, so it is better work from backwards:

for i:=@.numMU downto 1 loop
if @.MU(i).name="order_c" then
...
end;

next;
Steffen Bangsow
freelance simulation specialist  
web: www.bangsow.eu
mail: steffen@bangsow.net

Re: Cannot Access the MUs in Z dim of Transporter with for loop ?

Thank you Mr. Bangsow. That worked perfectly