Hi All,
       I am very new to Struts 2, so I don't know whether this issue is 
discussed before and has a solution. I had dynamic Result selection in my 
project. Where result would be selected on the basis of execution logic in 
Action method. 
For Example something like,
<action name="test" class="myPackage.Test" >
<result name="success">%{nextPage}</result>
</action> 
Where nextPage would be a property in Test class with settter and getter 
methods. And I would set it to whatever jsp page I want to execute.

It would work fine if Action method is successfully executed.
But the problem was that, if something happened and Action could not be 
executed, then result would not get invoked. i.e. if validation interceptor 
found validation errors or my RolesInterceptor found that user does not have 
access to that method. 
Framework would throw exception that result not found.
What can be done here?? Can I set a default nextPage before Interceptors are 
invoked?? Could writing an Interceptor for that help?? 

I know that as I am new to Struts 2 I could be doing something wrong. Can 
anyone help me??

Reply via email to