Thank you for your answer. I wasn't clear.
Here is the procedure I woul like:
1) First iteration r
2) First iteration d, excecute code (ind=...; PortPositions...)
3) JUMP to SECOND iteration r
4) go on to SECOND iteration d, excecute code...
5) JUMP to THIRD iteration r
6) go on to THIRD iteration d
...(and so on)
I hope that I was clear this time. I think that these kind of questions arrive a lot... specially for programmers who write codes in other programs . (for which go to command exists)