Please see below .. Sonam Belbase wrote:
I'm trying to understand ActionForms a bit better and here is my question:
If the servlet controller automatically invokes the reset() method before passing the ActionForm bean to the Action implementation class instance, how can you use the form's properties' values in your action?
After reset() is invoked, struts populate the ActionForm Bean .
FYI: Struts populate ActionForm Bean with all request params (post/get/...) using reflection.
We downcast in Action because in Action we receive base class "ActionForm".Is this why in the action, you need to downcast the form argument passed by the controller servlet to your Actionform as such:
String userName = ((LoginForm) form).getUserName();
Thanks, SB
Manish Singla
-- NOTICE: If received in error, please destroy and notify sender. Sender does not waive confidentiality or privilege, and use is prohibited.
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
-- Thanks Manish Singla x73166
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

