Posted: 17 Jun 2015 4:18 EDT Last activity: 9 Oct 2015 3:12 EDT
How can we get the current index of a Value List ?
How can we get the index of a Value List while iterating on the ForEachElementInValueList ? param.pyForEachCount holds the value of the current index for a Pagelist. but how can i get the value of the current index of a value list ?
Also is there a way to get the value of the last iterated valuelist ? Say i am now in 16th loop of a valuelist, adn i want to check the value of the 15th loop.
Leo, i have already gone through the help. My requirement is not to "To set or retrieve an element value from the end (highest index value) of a Value List" but from the middle, as in - the valuelist size is say 20, i might be iterating on loop 12 - i need the index for this loop as well as the index of loop 11.
Getting any one index will resolve the problem, coz if i get the value of the current index, i will set the value to a local variable and will be able to get the index of the previous iteration.
You can use Param.pyForEachCount parameter for current loop index, to get the value of the last iterated valuelist you can use Param.pyForEachCount -1 and get the value for that last iterated value from valuelist.