Hi, i have a link in my home.jsp called updateProfile.jsp, when the user clicks on it i am suppose to forward it to an action called /updateProfile.do, then in the execute method i gather all the info from UTIL class which interacts with D/B, so far i am able to do everything, now i want to populate all the info i have gathered in the actionform which is called ProfileForm, my first question is do i have to make a new instance of it? or i can cast it from the form attribute of the execute method?. how to i put this form in the request? i mean which key will the struts controller will be looking for so that it populates it?
if anyone can give me a small working example that will be really appreciated.
1. If I'm understanding you correctly no you don't need a new instance, dynamicly cast the form in your execute method and you're set
2. The form is automatically put on the request if you use the <form-bean> mapping in the struts config, the name of the form in this mapping is the name of the bean on the request and you can access it's properties like any other bean.