You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Giampiero Granatella <gr...@gmail.com> on 2009/04/18 12:14:21 UTC

Problem in creating a Custom Component with a Panel and a Form

Hi, I'm new to wicket and i'm trying to create a custom component with
a panel and inside the panel a form.
I've a problem in rendering it.

The framework tells me the following RuntimeException.

"...WicketMessage: The component(s) below failed to render. A common
problem is that you have added a component in code but forgot to
reference it in the markup (thus the component will never be
rendered).

1. [MarkupContainer [Component id = form]]
2. [MarkupContainer [Component id = url]]
3. [MarkupContainer [Component id = username]]
4. [MarkupContainer [Component id = password]]
5. [MarkupContainer [Component id = driver]]
6. [MarkupContainer [Component id = db]]
7. [MarkupContainer [Component id = submit]]

..."

But I have that components in the code (see below)

#  	Path  	Size  	Type  	Model Object
   	
2    	panel2    	2,9K
	com.manydesigns.portofino.web.components.DBParamPanel
3    	panel2:form    	2,3K    	org.apache.wicket.markup.html.form.Form    	
4    	panel2:form:db    	1K
	org.apache.wicket.markup.html.form.TextField
5    	panel2:form:driver    	1K
	org.apache.wicket.markup.html.form.TextField
6    	panel2:form:jndi    	1K
	org.apache.wicket.markup.html.form.TextField
7    	panel2:form:password    	1,1K
	org.apache.wicket.markup.html.form.PasswordTextField
8    	panel2:form:submit    	4,6K
	org.apache.wicket.markup.html.form.Button    	seleziona
9    	panel2:form:url    	1K
	org.apache.wicket.markup.html.form.TextField
10    	panel2:form:username    	1K
	org.apache.wicket.markup.html.form.TextField

And the template for the panel is the following

<wicket:panel>
    <h1>Form</h1>

    <form wicked:id="form">


        <input type="text" wicked:id="db"></input> <br/>
        <input type="text" wicked:id="url"></input> <br/>
        <input type="text" wicked:id="jndi"></input> <br/>
        <input type="text" wicked:id="username"></input> <br/>
        <input type="password" wicked:id="password"></input> <br/>
        <input type="text" wicked:id="driver"></input> <br/>

       <input type="submit" wicked:id="submit"></input> <br/>

    </form>
</wicket:panel>

Please someone can tell me what I do wrong?

Thanks a lot,
Giampiero Granatella

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


Re: Problem in creating a Custom Component with a Panel and a Form

Posted by Giampiero Granatella <gr...@gmail.com>.
It's time to change my glasses. :-)
Sorry for the stupid question...

Thanks a lot Gabriel

Giampiero

2009/4/18 Khlystov Alexandr <ak...@ovservice.org>:
>
> :).
> Gabriel Bucher пишет:
>>
>> write wicket with a 't' instead of a 'd' in the markup.
>> for example:
>> <input type="text" wicket:id="db"></input> <br/>
>> ^^^^^^^^^
>>
>> cheers gab
>>
>> Giampiero Granatella wrote:
>>>
>>> Hi, I'm new to wicket and i'm trying to create a custom component with
>>> a panel and inside the panel a form.
>>> I've a problem in rendering it.
>>>
>>> The framework tells me the following RuntimeException.
>>>
>>> "...WicketMessage: The component(s) below failed to render. A common
>>> problem is that you have added a component in code but forgot to
>>> reference it in the markup (thus the component will never be
>>> rendered).
>>>
>>> 1. [MarkupContainer [Component id = form]]
>>> 2. [MarkupContainer [Component id = url]]
>>> 3. [MarkupContainer [Component id = username]]
>>> 4. [MarkupContainer [Component id = password]]
>>> 5. [MarkupContainer [Component id = driver]]
>>> 6. [MarkupContainer [Component id = db]]
>>> 7. [MarkupContainer [Component id = submit]]
>>>
>>> ..."
>>>
>>> But I have that components in the code (see below)
>>>
>>> # Path Size Type Model Object
>>>
>>> 2 panel2 2,9K
>>> com.manydesigns.portofino.web.components.DBParamPanel
>>> 3 panel2:form 2,3K org.apache.wicket.markup.html.form.Form
>>> 4 panel2:form:db 1K
>>> org.apache.wicket.markup.html.form.TextField
>>> 5 panel2:form:driver 1K
>>> org.apache.wicket.markup.html.form.TextField
>>> 6 panel2:form:jndi 1K
>>> org.apache.wicket.markup.html.form.TextField
>>> 7 panel2:form:password 1,1K
>>> org.apache.wicket.markup.html.form.PasswordTextField
>>> 8 panel2:form:submit 4,6K
>>> org.apache.wicket.markup.html.form.Button seleziona
>>> 9 panel2:form:url 1K
>>> org.apache.wicket.markup.html.form.TextField
>>> 10 panel2:form:username 1K
>>> org.apache.wicket.markup.html.form.TextField
>>>
>>> And the template for the panel is the following
>>>
>>> <wicket:panel>
>>> <h1>Form</h1>
>>>
>>> <form wicked:id="form">
>>>
>>>
>>> <input type="text" wicked:id="db"></input> <br/>
>>> <input type="text" wicked:id="url"></input> <br/>
>>> <input type="text" wicked:id="jndi"></input> <br/>
>>> <input type="text" wicked:id="username"></input> <br/>
>>> <input type="password" wicked:id="password"></input> <br/>
>>> <input type="text" wicked:id="driver"></input> <br/>
>>>
>>> <input type="submit" wicked:id="submit"></input> <br/>
>>>
>>> </form>
>>> </wicket:panel>
>>>
>>> Please someone can tell me what I do wrong?
>>>
>>> Thanks a lot,
>>> Giampiero Granatella
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>> For additional commands, e-mail: users-help@wicket.apache.org
>>>
>>>
>>> !DSPAM:49e9a81b171425432119130!
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
>>
>>
>
>
> --
> Khlystov Alexandr
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>

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


Re: Problem in creating a Custom Component with a Panel and a Form

Posted by Khlystov Alexandr <ak...@ovservice.org>.
:).
Gabriel Bucher пишет:
> write wicket with a 't' instead of a 'd' in the markup.
> for example:
> <input type="text" wicket:id="db"></input> <br/>
> ^^^^^^^^^
>
> cheers gab
>
> Giampiero Granatella wrote:
>> Hi, I'm new to wicket and i'm trying to create a custom component with
>> a panel and inside the panel a form.
>> I've a problem in rendering it.
>>
>> The framework tells me the following RuntimeException.
>>
>> "...WicketMessage: The component(s) below failed to render. A common
>> problem is that you have added a component in code but forgot to
>> reference it in the markup (thus the component will never be
>> rendered).
>>
>> 1. [MarkupContainer [Component id = form]]
>> 2. [MarkupContainer [Component id = url]]
>> 3. [MarkupContainer [Component id = username]]
>> 4. [MarkupContainer [Component id = password]]
>> 5. [MarkupContainer [Component id = driver]]
>> 6. [MarkupContainer [Component id = db]]
>> 7. [MarkupContainer [Component id = submit]]
>>
>> ..."
>>
>> But I have that components in the code (see below)
>>
>> # Path Size Type Model Object
>>
>> 2 panel2 2,9K
>> com.manydesigns.portofino.web.components.DBParamPanel
>> 3 panel2:form 2,3K org.apache.wicket.markup.html.form.Form
>> 4 panel2:form:db 1K
>> org.apache.wicket.markup.html.form.TextField
>> 5 panel2:form:driver 1K
>> org.apache.wicket.markup.html.form.TextField
>> 6 panel2:form:jndi 1K
>> org.apache.wicket.markup.html.form.TextField
>> 7 panel2:form:password 1,1K
>> org.apache.wicket.markup.html.form.PasswordTextField
>> 8 panel2:form:submit 4,6K
>> org.apache.wicket.markup.html.form.Button seleziona
>> 9 panel2:form:url 1K
>> org.apache.wicket.markup.html.form.TextField
>> 10 panel2:form:username 1K
>> org.apache.wicket.markup.html.form.TextField
>>
>> And the template for the panel is the following
>>
>> <wicket:panel>
>> <h1>Form</h1>
>>
>> <form wicked:id="form">
>>
>>
>> <input type="text" wicked:id="db"></input> <br/>
>> <input type="text" wicked:id="url"></input> <br/>
>> <input type="text" wicked:id="jndi"></input> <br/>
>> <input type="text" wicked:id="username"></input> <br/>
>> <input type="password" wicked:id="password"></input> <br/>
>> <input type="text" wicked:id="driver"></input> <br/>
>>
>> <input type="submit" wicked:id="submit"></input> <br/>
>>
>> </form>
>> </wicket:panel>
>>
>> Please someone can tell me what I do wrong?
>>
>> Thanks a lot,
>> Giampiero Granatella
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
>>
>> !DSPAM:49e9a81b171425432119130!
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
>


-- 
Khlystov Alexandr


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


Re: Problem in creating a Custom Component with a Panel and a Form

Posted by Gabriel Bucher <ga...@gmail.com>.
write wicket with a 't' instead of a 'd' in the markup.
for example:
<input type="text" wicket:id="db"></input> <br/>
                    ^^^^^^^^^

cheers gab

Giampiero Granatella wrote:
> Hi, I'm new to wicket and i'm trying to create a custom component with
> a panel and inside the panel a form.
> I've a problem in rendering it.
> 
> The framework tells me the following RuntimeException.
> 
> "...WicketMessage: The component(s) below failed to render. A common
> problem is that you have added a component in code but forgot to
> reference it in the markup (thus the component will never be
> rendered).
> 
> 1. [MarkupContainer [Component id = form]]
> 2. [MarkupContainer [Component id = url]]
> 3. [MarkupContainer [Component id = username]]
> 4. [MarkupContainer [Component id = password]]
> 5. [MarkupContainer [Component id = driver]]
> 6. [MarkupContainer [Component id = db]]
> 7. [MarkupContainer [Component id = submit]]
> 
> ..."
> 
> But I have that components in the code (see below)
> 
> #  	Path  	Size  	Type  	Model Object
>    	
> 2    	panel2    	2,9K
> 	com.manydesigns.portofino.web.components.DBParamPanel
> 3    	panel2:form    	2,3K    	org.apache.wicket.markup.html.form.Form    	
> 4    	panel2:form:db    	1K
> 	org.apache.wicket.markup.html.form.TextField
> 5    	panel2:form:driver    	1K
> 	org.apache.wicket.markup.html.form.TextField
> 6    	panel2:form:jndi    	1K
> 	org.apache.wicket.markup.html.form.TextField
> 7    	panel2:form:password    	1,1K
> 	org.apache.wicket.markup.html.form.PasswordTextField
> 8    	panel2:form:submit    	4,6K
> 	org.apache.wicket.markup.html.form.Button    	seleziona
> 9    	panel2:form:url    	1K
> 	org.apache.wicket.markup.html.form.TextField
> 10    	panel2:form:username    	1K
> 	org.apache.wicket.markup.html.form.TextField
> 
> And the template for the panel is the following
> 
> <wicket:panel>
>     <h1>Form</h1>
> 
>     <form wicked:id="form">
> 
> 
>         <input type="text" wicked:id="db"></input> <br/>
>         <input type="text" wicked:id="url"></input> <br/>
>         <input type="text" wicked:id="jndi"></input> <br/>
>         <input type="text" wicked:id="username"></input> <br/>
>         <input type="password" wicked:id="password"></input> <br/>
>         <input type="text" wicked:id="driver"></input> <br/>
> 
>        <input type="submit" wicked:id="submit"></input> <br/>
> 
>     </form>
> </wicket:panel>
> 
> Please someone can tell me what I do wrong?
> 
> Thanks a lot,
> Giampiero Granatella
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
> 
> 
> !DSPAM:49e9a81b171425432119130!
> 


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


Re: Problem in creating a Custom Component with a Panel and a Form

Posted by Khlystov Alexandr <ak...@ovservice.org>.
Maybe hierarchy doesn't match? Means you added the panel to to other 
panel at java, but at html panel is added to the page directly.

If not please provide more data - your java code.

Giampiero Granatella пишет:
> Hi, I'm new to wicket and i'm trying to create a custom component with
> a panel and inside the panel a form.
> I've a problem in rendering it.
>
> The framework tells me the following RuntimeException.
>
> "...WicketMessage: The component(s) below failed to render. A common
> problem is that you have added a component in code but forgot to
> reference it in the markup (thus the component will never be
> rendered).
>
> 1. [MarkupContainer [Component id = form]]
> 2. [MarkupContainer [Component id = url]]
> 3. [MarkupContainer [Component id = username]]
> 4. [MarkupContainer [Component id = password]]
> 5. [MarkupContainer [Component id = driver]]
> 6. [MarkupContainer [Component id = db]]
> 7. [MarkupContainer [Component id = submit]]
>
> ..."
>
> But I have that components in the code (see below)
>
> #  	Path  	Size  	Type  	Model Object
>    	
> 2    	panel2    	2,9K
> 	com.manydesigns.portofino.web.components.DBParamPanel
> 3    	panel2:form    	2,3K    	org.apache.wicket.markup.html.form.Form    	
> 4    	panel2:form:db    	1K
> 	org.apache.wicket.markup.html.form.TextField
> 5    	panel2:form:driver    	1K
> 	org.apache.wicket.markup.html.form.TextField
> 6    	panel2:form:jndi    	1K
> 	org.apache.wicket.markup.html.form.TextField
> 7    	panel2:form:password    	1,1K
> 	org.apache.wicket.markup.html.form.PasswordTextField
> 8    	panel2:form:submit    	4,6K
> 	org.apache.wicket.markup.html.form.Button    	seleziona
> 9    	panel2:form:url    	1K
> 	org.apache.wicket.markup.html.form.TextField
> 10    	panel2:form:username    	1K
> 	org.apache.wicket.markup.html.form.TextField
>
> And the template for the panel is the following
>
> <wicket:panel>
>     <h1>Form</h1>
>
>     <form wicked:id="form">
>
>
>         <input type="text" wicked:id="db"></input> <br/>
>         <input type="text" wicked:id="url"></input> <br/>
>         <input type="text" wicked:id="jndi"></input> <br/>
>         <input type="text" wicked:id="username"></input> <br/>
>         <input type="password" wicked:id="password"></input> <br/>
>         <input type="text" wicked:id="driver"></input> <br/>
>
>        <input type="submit" wicked:id="submit"></input> <br/>
>
>     </form>
> </wicket:panel>
>
> Please someone can tell me what I do wrong?
>
> Thanks a lot,
> Giampiero Granatella
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
>
>   


-- 
Khlystov Alexandr


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