wood burning stoves 2.0*
The moose likes Struts and the fly likes how to deal with this type of ActionForm Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "how to deal with this type of ActionForm" Watch "how to deal with this type of ActionForm" New topic
Author

how to deal with this type of ActionForm

Rajeev Ja
Ranch Hand

Joined: May 06, 2007
Posts: 38
class DepositData extends ActionForm
{
private Patient patient=null;
//contains getters and setters
}
class Patient
{
private String patientId;
}

can any one tell how to deal with action class and how to retrieve
patientId in JSP
Thanks and Regards
Rajeev
James Ward
Ranch Hand

Joined: Apr 27, 2003
Posts: 263
In the execute method of your action class, you have access to the request and response objects! So you can add whatever you like to them and access them in your JSP!
Brent Sterling
Ranch Hand

Joined: Feb 08, 2006
Posts: 948
The general form using html tags is property="patient.patientId". This assumes that you have matching get methods: getPatient().getPatientId().

- Brent
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: how to deal with this type of ActionForm
 
Similar Threads
detached entity passed to persist
Dispatch[/ActionName ] to method method1 returned an exception
Why is my WS expecting a XMLGregorianCalendar datatype?
Code error
Getting cast exception....