File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes dynamic indexed properties Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "dynamic indexed properties" Watch "dynamic indexed properties" New topic
Author

dynamic indexed properties

Janis Olex
Greenhorn

Joined: Aug 21, 2003
Posts: 12
So what is standard approach of Struts framework to add dynamically some properties to the FormBean?
My FormBean has "skills" properties which is List!
I have "Add Skill" button on my form which I want to add one element to this form! The problem is that each time I redirect to the page constructor is called for my FormBean (which is logical as it's lifecycle is one request) and I can't add those skills as the next time Struts will seek for my added skills property it won't find it as it is recreated on each construction of this FormBean!
How can I make the FormBean remember it's collection?
Also how do I fill up FormBean before it shows up with some data from my persistence layer?


-----<br />Programmers are tools to convert cofein into code.
Junilu Lacar
Bartender

Joined: Feb 26, 2001
Posts: 5288
    
  10

See my reply in this thread


Junilu - [How to Ask Questions] [How to Answer Questions]
 
Don't get me started about those stupid light bulbs.
 
subject: dynamic indexed properties