You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by er...@mindspring.com on 2005/08/31 01:44:24 UTC
Need help with dynamic number of form fields
Hello all. I am not good with Dyna forms. What I am trying to accomplish is to set up a form that allows a random number of each logical field to be populated. I know this discussion came up recently, but I don't exactly know what to search for in the archives.
This approximates what I am trying to do:
<form-bean name="fooForm" type="org.apache.struts.action.DynaActionForm">
<form-property name="fooName" type="java.lang.String[]" />
The point is to allow the user to add as many Foos as he wants. Each time he clicks an "add" button, I provide a new field. So the ActionForm has to be able to handle an undeterminable number of Foos.
What is the best way to handle this, ActionForm-wise? Can someone point me to a resource?
Thanks,
Erik
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org