That must be it. I'll try it out. Thanks!

Damian Mendez Romera wrote:
> 
> You must override the onError method and add a 
> target.addComponent(feedback) :)
> 
> Gohan wrote:
>> I cannot seem to get the Feedback panel to be displayed on a Form submit. 
>>
>> I have a custom form component that extends Form to which I'm adding an
>> AjaxSubmitButton using:
>> add(new AjaxSubmitButton("submit", this) {
>>              private static final long serialVersionUID = 
>> 4557185412512174512L;
>>              @Override
>>              protected void onSubmit(AjaxRequestTarget target, Form form) {
>>                      fromDate = (Date) fromDateField.getConvertedInput();
>>                      toDate = (Date) toDateField.getConvertedInput();
>>
>>                      target.addComponent(nbrOfAuthenticationsChart);
>>                      target.addComponent(feedbackPanel);
>>              }
>>  });
>>
>> The feedback panel is added using (it's located outside the form in
>> another
>> component):
>> add(feedbackPanel = new FeedbackPanel("feedback"));
>> feedbackPanel.setOutputMarkupId(true);
>>
>> I've also added an AjaxFormValidatingBehavior to the form: 
>> AjaxFormValidatingBehavior.addToAllFormComponents(this, "onclick"); 
>> and I'm using a special form validator that extends AbstractFormValidator
>> that I've also added to the custom form.
>>
>> The ajax submission works when I press the submit button but there are no
>> form errors displayed if there are any errors. The problem seem to be
>> that
>> the feedback panel is never displayed and I cannot seem to figure out
>> why.
>> I'm using Wicket 1.2.6. I've looked in the example at
>> http://www.wicket-library.com/wicket-examples/ajax?wicket:bookmarkablePage=:wicket.examples.ajax.builtin.FormPage
>> but that example doesn't seem to work at all. 
>>
>> Could anyone give me a clue?
>>
>>
>>
>>   
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Feedback-is-not-dispayled-in-ajax-submit-tf4213023.html#a11986208
Sent from the Wicket - User mailing list archive at Nabble.com.


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

Reply via email to