Yes, I think you are doing it "the Wicket way", but your snippet and mine should work. Do you modify components' model somewhere else? Which model do you get if you call getDefaultModel() inside oninitialize?
Thanks for your reply. I've tried it but it still gave the same error.

However I also tried the following modified version of your idea:

In AddressPanel.java:

@Override
protected void onInitialize() {
        super.onInitialize();
        Object o = getDefaultModelObject();

        setDefaultModel(new CompoundPropertyModel(getDefaultModelObject()));
}

With the above code I can now load the page, also the getDefaultModelObject() returns the 
correct Address instance. Unfortunately upon submitting the form I get the same exception 
again ("No get method defined for class: class foo.HomePage expression: 
street").

By the way: am I doing things "the Wicket way"? Is this how you would reuse 
parts of a form in Wicket?



Best regards,

Bob



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to