mosho wrote:
Request[/planName] does not contain handler parameter named navigation
In your struts-config.xml, are you including 'parameter="navigation"' in
your action mapping? A la:
<action path="/planName" type="my.pkg.PlanNameAction"
name="planNameForm" parameter="navigation">
...
</action>
The parameter gives you a place to pass additional data to your action.
In the case of LookupDispatchAction, it uses it to find out which
request parameter (in this case, "navigation") it should look at to
determine which method to call in your subclass. So your form will
submit, and be stuff like:
navigation=Next%20Record
It looks messy, but that's OK. The framework takes it and translates it
back into "Next Record". Now in your subclass, you override
getKeyMethodMap() right? And somewhere in there, you have something like,
map.put( "navigation.next.record", "next" );
Where "next" corresponds to the public ActionForward next(
ActionMapping.......) method you have defined in your subclass.
And in your MessageResources.properties (or whatever the file's called
in your web app), you have:
navigation.next.record=Next Record
See how everything links together? Now the button text you choose is
likely different, but this flexibility is the reason you NEVER refer to
the button by its text. Let Struts do that internally, only your users
should see it. Just thought I'd give you a little background so you
know what you're getting into; anyone correct me if I'm wrong :)
Oh one last thing. Make sure you're NOT overriding execute() in your
subclass. It's fine for regular Action-derived classes, but you're
using LookupDispatchAction, which needs to run its own implementation of
execute().
- Scott
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]