You should always populate aBean to the form in the action.

But you should also "populate" a empty aBean in the constructor of the form,
to avoid a NullPointerException.

regards,
Bernhard


-----Ursprüngliche Nachricht-----
Von: Denis Wang [mailto:dwang@;brandmuscle.com]
Gesendet: Dienstag, 12. November 2002 14:43
An: Struts Users Mailing List
Betreff: RE: how to populate nested bean in actionform


Thanks for your reply.  I know I can "read" the filed as you described.
What if I want to populate the field?

Where should I populate aBean?
Should I initiate aBean in the default constructor of aForm?
Should I initiate it from Action?
I am trying.  If I got a solution, I will post the solution.
Thanks again for your attention.
Denis

--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@;jakarta.apache.org>

Reply via email to