You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Sam Barrow <sa...@sambarrow.com> on 2009/09/29 04:28:27 UTC
Attempt to set model object on null model of component
I'm getting this exception:
java.lang.IllegalStateException: Attempt to set model object on null
model of component: form:agent
The only reason i can find is that the field has a null model, but i added a new Model() to the field and im still getting it
DropDownChoice<Agent> agent = new DropDownChoice<Agent>("agent", new Model<Agent>(), agentList);
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: Attempt to set model object on null model of component
Posted by Pedro Santos <pe...@gmail.com>.
You need to find if the component who throw the exception is the same agent
constructed with lines you report and on what moment the component lost his
model.
On Mon, Sep 28, 2009 at 11:28 PM, Sam Barrow <sa...@sambarrow.com> wrote:
> I'm getting this exception:
> java.lang.IllegalStateException: Attempt to set model object on null
> model of component: form:agent
>
> The only reason i can find is that the field has a null model, but i added
> a new Model() to the field and im still getting it
>
> DropDownChoice<Agent> agent = new DropDownChoice<Agent>("agent", new
> Model<Agent>(), agentList);
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
--
Pedro Henrique Oliveira dos Santos