Targeting Specific Elements in a Repeater


#1

Hi,

Please see attached Axure file for specifics.

I’m having trouble targeting a specific instance of a repeater. For example, when adding a new row I want to give the field label a unique name. However, I don’t know how to target it, and thus, all the field labels end up with the same name. Likewise, I want to have the ability to remove a field label/text input, but I’m having the same issues with that as well. I can’t seem to figure out how to remove just that one instance of the repeater.

What am I doing wrong or not doing?

Thanks,

DRCtargeting specific repeater instances.rp (6.3 MB)


#2

Hi!

I’m not sure which page of the prototype you are referring to. The page it was on when I opened it was “dynamic search builder v2,” but I didn’t see any Add Rows command on that page.

To set the label of a new row, do the following:

  • Create a column called “label” or whatever in your dataset
  • In OnItemLoad, set the label in the repeater row to the column value. E.g., Set (label widget) to [[Item.label]]
  • When you add the row, specify what to set the “label” column.

As far as targeting which row to delete, that would depend on whether the delete function is inside or outside of the repeater…