repeat index is always 1

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

repeat index is always 1

JohnBampton
I have a xforms:repeat and it's iterating over a set of identical elements.

In the user interface there is a yellow row highlighting the first html table row that the repeat outputs.

When I try to use the index function to get the position of the loop it always returns 1.

Why is this?
Reply | Threaded
Open this post in threaded view
|

Re: repeat index is always 1

Erik Bruchez
Administrator
John,

The index represents the currently selected repeat row. If you don't
use xf:setindex to change that, or if the user doesn't click on
another repeat iteration, the index will stay 1.

If you are looking for the position, use the position() function instead.

-Erik

On Wed, Jan 12, 2011 at 11:20 PM, JohnBampton <[hidden email]> wrote:

>
> I have a xforms:repeat and it's iterating over a set of identical elements.
>
> In the user interface there is a yellow row highlighting the first html
> table row that the repeat outputs.
>
> When I try to use the index function to get the position of the loop it
> always returns 1.
>
> Why is this?
> --
> View this message in context: http://orbeon-forms-ops-users.24843.n4.nabble.com/repeat-index-is-always-1-tp3215338p3215338.html
> Sent from the Orbeon Forms (ops-users) mailing list archive at Nabble.com.
>
>
> --
> You receive this message as a subscriber of the [hidden email] mailing list.
> To unsubscribe: mailto:[hidden email]
> For general help: mailto:[hidden email]?subject=help
> OW2 mailing lists service home page: http://www.ow2.org/wws
>
>


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws