Hi

Use the Switch Action.

Hermod

-----Original Message-----
From: Diego Manilla Suárez [mailto:[EMAIL PROTECTED]
Sent: Thursday, January 27, 2005 1:54 PM
To: Struts Users Mailing List
Subject: Process tiles definition from a different module


Hi! I need to process a tiles definition that is located in a different 
module. I have this ActionForward declared on the module I want to
invoke:

<forward name="myPage" path=".myTilesDefinition" redirect="false"/>

And on the main module, I have this code (in an action) to get that 
forward definition.

ActionForward forward = null;
ServletContext context = getServlet().getServletContext();
ModuleConfig config = 
ModuleUtils.getInstance().getModuleConfig("othermodule", context);
if (config != null && 
"org.apache.struts.action.ActionForward".equals(config.getActionForwardC
lass())) 
{
       forward = (ActionForward)config.findForwardConfig("myPage");
}
return forward;

This doesn't work because Tiles is not processing the definition 
".myTilesDefinition" (I have two separate Tiles definition 
configurations, one for each module). How can I get the definition on 
the other module processed by Tiles?

I know I can import the definitions of the second module using 
<set-property property="definitions-config" ...> in struts-config.xml, 
but I'm wondering if it's possible to do what I want without this 
"trick". With TilesUtilStrutsModulesImpl class I get the 
DefinitionsFactory object for the second module, but I can't get past
there.

Thanks in advance.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

This email with attachments is solely for the use of the individual or
entity to whom it is addressed. Please also be aware that the DnB NOR Group
cannot accept any payment orders or other legally binding correspondence with
customers as a part of an email. 

This email message has been virus checked by the virus programs used
in the DnB NOR Group.

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to