Why do you need a form?  Just use an AjaxLink.  And, do the check in
the onClick() method.

On Tue, Mar 22, 2011 at 4:58 PM, Steve Lowery
<[email protected]> wrote:
> I have a Form object whose only child is an AjaxSubmitLink.  The Form's
> onSubmit() calls to a service to delete its model object (from the
> underlying database).  I would like to add validation to make sure that the
> model can be deleted (i.e. there are no foreign keys referencing it) before
> attempting to do it.  I thought I could achieve this with an
> AbstractFormValidator, but if I detect the error in the validate() method,
> all of the error methods on AbstractFormValidator expect a FormComponent,
> which I don't have.
>
> What is the best way to accomplish validating a Form that does not have a
> FormComponent?
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to