Hi Carlin,
In the new annotation based validation I can user ${pageflow.xxxx} in the form
bean. I am looking for a way to do this in old style form bean also
Some of the fields are required based on some conditional variables defined in
the pageflow. I can as well set those variables in the form bean also.
Thank You
Srinivas Surapaneni
-------------- Original message --------------
From: "Carlin Rogers" <[EMAIL PROTECTED]>
> Hi Srinivas,
>
> In the case you described, the form bean does not have access to the page
> flow. In your design, how come the form bean would want/need access to the
> page flow? Just curious about the use case.
>
> When you ask about "...using the old style validate method in the form
> bean", do you mean implementing a form bean that extends ActionForm and
> overrides the validate() method? If so, yes, this is supported if you'd
> rather do that than use the validator support in NetUI. To do this, you need
> to add the doValidate and validationError properties to your
> Jpf.Actionannotation... something like the following snippet.
>
> @Jpf.Action(
> doValidation=true,
> validationErrorForward =
> @Jpf.Forward(
> name = "fail",
> navigateTo=Jpf.NavigateTo.currentPage),
> forwards = {
> @Jpf.Forward(
> name = "success",
> path = "next.jsp")
> })
> public Forward myAction(MyForm form) {
> ...
> }
>
> Hope that helps,
> Carlin
>
>
> On 3/3/06, Srinivas Surapaneni wrote:
> >
> > I had a form bean which is not a inner class
> >
> >
> >
> > How do I access the pageflow from the form bean?
> >
> >
> >
> > Can we still validate using the old style validate method in the form
> > bean?
> >
> >
> >
> >
> >
> > Thanks
> >
> > Srinivas Surapaneni
> >
> >
> > --
> > No virus found in this outgoing message.
> > Checked by AVG Free Edition.
> > Version: 7.1.375 / Virus Database: 268.1.1/273 - Release Date: 3/2/2006
> >
> >
> >
>