I'm doing the same exact thing right now.  It took some doing to figure out
how to make it work.  But anyway, I have an EntryHolder class in the session
that stores a few ArrayLists of entries.  It also stores a String[] of the
entry numbers to delete.  The following code gets the selected index numbers
and stores them in that deletion array.  When the form is submitted, the
user is taken to a confirmation page.  When the user clicks the confirmation
link, the action calls a method on the EntryHolder class that simply tells
it to delete the selected entries, which is simple to do.
The code in my JSP includes the following:
________________________________________________

<html:form action="/EditEntry.do?action=confirm&type=md">
        <table border="0">
                <tbody align="left">
        <logic:iterate id="md" name="entries" property="mdEntries"
type="com.moog.us.eos.beans.MDentry" indexId="index">
      <tr>
        <td>
                        <html:checkbox name="entries" property="selections"
value="<%=index.toString()%>"/>
                </td>
        <td>
                        <bean:write name="md" property="label"/>
                </td>
        </tr>
        </logic:iterate>
                </tbody>
        </table>
        <html:submit value="Delete Selected Entries"/>
</html:form>
________________________________________________

My solution may be somewhat unconventional, but I think it works great.  I'm
not sure how applicable this design is to what you're doing, but it sounds
like you're trying to do the same thing.  However, if you're using the
Display Tag Lib and displaying info column by column, you'll just have to
make some changes in the JSP.  Should be pretty simple though.
I hope this helps.

~ Keith
http://www.buffalo.edu/~kkamholz



-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]
Sent: Thursday, July 11, 2002 4:39 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: Display Tag Library



You mentioned that you had a bunch of features.... You dont happen to 
have one that works with the multicheckbox control?  I want to add a 
delete checkbox to each row...






-----Original Message-----
From: lists [mailto:[EMAIL PROTECTED]]
Sent: Thursday, July 04, 2002 12:29 AM
To: struts-user
Subject: RE: Wow - Continued...


> -----Original Message-----
> From: [EMAIL PROTECTED]
> -------------------------------------------
> The Display Tag library  ( http://edhill.its.uiowa.edu/display/ )
> This was the best one I could find for it, although the documentation 
is
> somewhat lacking and required some source diving to learn that I could
> do grouping and such.  It supports Dynabeans and does all kinds of 
nice
> looking things...  I could go into it all now, but if you go to the 
web
> site its all already described.

Ed had a BOF at JavaOne this year to sort of show how he came up with 
that
tag lib and how it works. It's very straightforward, easy to use, and 
easy
to modify. I've already added a bunch of features that I'm going to 
submit
back to him, and they all were extremely easy to implement. If anybody 
has a
table tag they are in love with that seems like it's better than this, 
I'd
love to hear about it!

Joe


--
To unsubscribe, e-mail:   
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: 
<mailto:[EMAIL PROTECTED]>



--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to