<APPEND> and <CURRENT> mismatch in a loop in activity

E.g.

In an activity loop, I do and on same page list conditionally.

In first 3 loops, condition is true, so and are run for the page list, now there are 3 pages there.

in 4rd loop, condition is false, both the steps calling xxx.pxResults() and following are skipped,

then in 5th loop, condition is true again, the add 4rd page into page list, BUT, is referring to 5th page (does not exist at all).

Any idea for the reason and any solution?

@MaxonL16591286

Current looks for the loop count you’re in. If you’re using embedded page for looping, the pyForEachCOunt parameter can be referred when you trace. As you mentioned 5th loop is taking 5th page, it is because the loop count is 5 by that time but since append didn’t happen at loop 4 iteration, the 4th page got appended in loop 5.

I’m assuming that the latest page that gets added needs a new property-set to be done. Instead of , please proceed with

If your requirement is something else, please post it here.

@MaxonL16591286

Instead of , try using . So after you suppose on the 3rd page, then the 4th page is created. So in that loop the index is also 4.

@Pavan_kalyan LAST works, thanks!