I also got a similar exception, and for me the reason was that I had
different form field name and bean property name. Make sure that the form
that you are submitting have the field names same as the ActionForm bean's
properties.



-----Original Message-----
From: Firmin David [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 08, 2001 7:53 AM
To: '[EMAIL PROTECTED]'
Subject: Help! Can't access ActionForm properties in Action perform()!


Hi all
I've done something stupid. I know I have, but I can't figure out what....
I'm trying to access the data entered by the user from the corresponding
formbean in my action's perform method (really rudimentary stuff, I know),
and I keep getting null pointers.
I've followed exactly what was done in the example app:

perform(blah blah, ActionForm form, etc.etc.){
        MyForm thisForm = (MyForm) form;
        thisForm.getSomething();
}

but my getSomething() gets nothing, and all I get is a null pointer
exception, because thisForm == null. 
I'm fairly sure I've rooted through the documentation, but can't find much
in the way of help.

Anyone got any idea what I've overlooked? I know everything is mapped right,
as the input is validated successfully in the formbean, and the correct
action is called.

Thanks in advance

Rgds
David

************************************************************************
The information in this email is confidential and is intended solely
for the addressee(s).
Access to this email by anyone else is unauthorised. If you are not
an intended recipient, you must not read, use or disseminate the
information contained in the email.
Any views expressed in this message are those of the individual sender,
except where the sender specifically states them to be the views of
The Capital Markets Company.

http://www.capco.com
***********************************************************************

Reply via email to