Hello guys, I'm having a little problem with the use of AjaxFormValidatingBehavior. I add it to all my fields, using a visitor. form.visitChildren(FormComponent.class, new IVisitor() { public Object component(Component component) { if (component instanceof TextField) { component.add(new AjaxFormValidatingBehavior(form, "onkeyup") { private static final long serialVersionUID = 1L; @Override protected void onError(AjaxRequestTarget target) { super.onError(target); updateFieldsCssClasses(); } @Override protected void onSubmit(AjaxRequestTarget target) { super.onSubmit(target); updateFieldsCssClasses(); } }); } else if (component instanceof DropDownChoice || component instanceof CheckBox) { component.add(new AjaxFormValidatingBehavior(form, "onclick") { private static final long serialVersionUID = 1L; @Override protected void onError(AjaxRequestTarget target) { super.onError(target); updateFieldsCssClasses(); } @Override protected void onSubmit(AjaxRequestTarget target) { super.onSubmit(target); updateFieldsCssClasses(); } }); } return null; } }); But when this code is rendered, it throws this exception: org.apache.wicket.util.io.SerializableChecker$WicketNotSerializableException: Unable to serialize class: xxx$10However, AjaxFormValidatingBehavior implements Seriablizable... so I don't understand why Wicket complains about it... Have I miss something? PS: it works this way under at least 1.3.0 and 1.3.1 --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] |
- AjaxFormValidatingBehavior: getting NotSerializableExc Sébastien Piller
- Re: AjaxFormValidatingBehavior: getting NotSerializ... Martijn Dashorst
- Re: AjaxFormValidatingBehavior: getting NotSeri... Sébastien Piller