I am sending the results from a checkbox in a display table and submit it to
my action. The code works fine for the first time, but it doesnt save
anything in the session, when i want to add more items, the previous values
are gone and only the current selection is saved in the list. How do I
retain the values in session when I try to add more items through the
checkbox?

Code in my jsp:
------------------------

         <d:column title="Add to Pack">
         <s:checkbox name="selectedMessages" value="${Task.task_Id}"/>
         </d:column>

---- <p><s:submit name="Add_to_Pack" value="Add to Pack"/></p>
----------------------------------------------------------------------------------------------------------------------------------------
Actionbean code:
--------------------------

@Session
private List<String> selectedMessages;
public List<String> getSelectedMessages() {
return selectedMessages;
}
public void setSelectedMessages(List<String> selectedMessages) {
this.selectedMessages = selectedMessages;
}

@HandlesEvent(value="Add_to_Pack")
    public Resolution Add_to_Pack() {
     return new ForwardResolution(VIEW);
    }


-- 
Best Regards,
Swarna
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Stripes-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/stripes-users

Reply via email to