spry:setrow and spry:setrownumber Attribute Sample

This page demonstrates the use of the spry:setrow and spry:setrownumber attributes. Both attributes require a single name of a data set as their value. After a spry:region or spry:detailregion is re-generated Spry will run through the resulting region content and attach a non-destructive click event handler to each element that has a spry:setrow or spry:setrownumber. For spry:setrow, this event handler calls setCurrentRow() with the ds_RowID of the row that was used at the time that particular element was generated. Likewise, for spry:setrownumber, the event handler calls setCurrentRowNumber() with the ds_RowNumber of the row that was used at the time that element was generated.

These attributes were meant to be used as a short cut, so instead of setting the current row on a click manually like this: