Jay, Make sure the following is after </action-mappings> in your struts config file (IF YOU HAVEN'T DONE SO ALREADY):
<plug-in className="org.apache.struts.tiles.TilesPlugin"> <set-property property="definitions-config" value="/WEB-INF/opus-tiles.xml" /> <set-property property="definitions-debug" value="2" /> <set-property property="definitions-parser-detail" value="2" /> <set-property property="definitions-parser-validate" value="true" /> </plug-in> where you point to your own opus-tiles.xml. Then, use the following mapping: <action path="/ViewSystemProperties" type="com.nci.action.telco.ViewSystemProperties" scope="request" name="SystemProperties" parameter="/telco_edit_system_properties" validate="false"> <forward name="success" path="telco.system_properties"/> </action> After you pre-populate your form in the ViewSystemProperties action..... return mapping.findForward("success"); -Jonathan -----Original Message----- From: Glanville, Jay [mailto:[EMAIL PROTECTED] Sent: Thursday, December 04, 2003 11:02 AM To: Struts User List Subject: How do I combine tiles and pre-populated forms? Hello All. I'm a nubie and I'm having a little problem. I need to combine an action mapping to pre-populate a form, with an action mapping for a tile definition. Let me go into more detail ... I have an action mapping that gets the information for a form, populates the form and then forwards on to the page containing the form. The mapping looks like this: <action path="/ViewSystemProperties" type="com.nci.action.telco.ViewSystemProperties" scope="request" name="SystemProperties" parameter="/telco_edit_system_properties" validate="false"> </action> The "name" attribute is a form bean I've defined in the <form-beans> section, which subclasses action form and does all the necessary validation of the form. The "type" in the above action is a subclass of Action which goes to the database and gets the appropriate information, and then sets the form's properties. The "type" class then uses the "parameter" attribute to forward on to our internal templating framework that we want to get rid of. As we want to get rid of our internal templating framework and use tiles, I came up with the following action mapping: <action path="/ViewSystemProperties" type="org.apache.struts.actions.ForwardAction" parameter="telco.system_properties"> </action> The "parameter" attribute is a tile definition (from tiles-def.xml). The problem with this is that I can't do the necessary work with pre-populating the form. With the first solution, I can pre-populate a form. With the second solution, I can use the tiling framework. Now the big question: how do I combine both solutions so that I can pre-populate my form and use the tiling framework? Thanks in advance. Jay Dickon Glanville PS: If this email comes through as HTML or RTF, I apologize. I BELIEVE I've setup this email for plain text, but I could be wrong. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]