Hi Apte.. Here is another simple sol. which gives you an array containing the row id's of all the checkBoxes which are checked...
I am using Display Tag to display the lists: <display:table defaultsort="3" class="" name="partItems" id="partItem" > <display:column titleKey="{*}"> <html:multibox name="partDetailForm" property="intarray"><%=partItem_rowNum%></html:multibox> </display:column> <display:column property="sku" paramId="Sku" title="SKU" align="right" /> <display:column property="partNo" title="Part Number" align="right" /> </display:table> In my ActionForm I have an int[] intarray which collects the values of the selected checkboxes. See the documentation of <html:multibox> at http://struts.apache.org/userGuide/struts-html.html#multibox. My Action works on the intarray to do the proper thing with the values. Remember to set intarray to zero length in the reset method of the ActionForm. Phani. --- "Apte, Dhanashree (Noblestar)" <[EMAIL PROTECTED]> wrote: > Hi all, > > I have a jsp which shows rows of data. Each row is > preceded by a checkbox. i > can check the boxes and hit a delete button and it > is supposed to delete the > selected rows. In my page i have: > > <logic:iterate id="aBean" name="myForm" > property="allRecords"> > <tr > class=<%RecordCounter++; > bgcolor = "alternateRow"; > if (RecordCounter % 2 == 1) > bgcolor = "normalRow"; > out.print(bgcolor);%>> > <td width=1%><html:checkbox name="aBean" > property="temporaryId" > value="temporaryId" /></td> > <td class=formDe><bean:write name="aBean" > property="attr1" /></td> > <td class=formDe><bean:write name="aBean" > property="attr2" /></td> > <td class=formDe><bean:write name="aBean" > property="attr3" /></td> > <td class=formDe><bean:write name="aBean" > property="attr4" /></td> > <td class=formDe><bean:write name="aBean" > property="attr5" /></td> > </tr> > </logic:iterate> > > I am unable to identify the rows uniquely by > clicking on the checkboxes. The > syntax for one of the two would help: > > I would like to use the value of the RecordCounter > to get submitted as the > checkbox value. (but i dont know the syntax). OR.. > > I would like to have the vaue of the field > temporaryId passed back. right > now, with what i have, i just get a String array > called temporaryId and > temporaryId[0] = "temporaryId", > temporaryID[1]="temporaryId". I want the > actual value of the temporaryId attribute back > instead of just > "temporaryId". > > Any help is appreciated. > > Thanks! > Dhanashree. > > __________________________________ Do you Yahoo!? Yahoo! Mail - Find what you need with new enhanced search. http://info.mail.yahoo.com/mail_250 --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]