JSF - dynamic fields

hello.

can anyone help me with that problem in JSF:

every time the <button_jsf> is clicked and the 'action' is invoked

the new component (containing 2 text input fields) is rendered in the <component_jsf>. What should be type of this component: UIPanel, UIComponent?

i've tried to do this using renderers, custom tags but without any success:/

[jsp page]

...

<button_jsf actionListener="action" />

<form_jsf>

<component_jsf>

[<this 2 input text fields are being rendered every time the'action' is invoked>]

...

</component_jsf>

</form_jsf>

...

[jsp page]

-

thanks,

matt

[822 byte] By [naked_ravena] at [2007-10-3 2:33:47]
# 1
Could you use a dataTable and add another row whenever action is invoked?
BrantKnudsona at 2007-7-14 19:32:46 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2

Yes. That's the point. Thanks.

So the last question is - should I rerender the datatable every time the action is invoked or just add a new row to existing table?

It's not a problem to do it using XML but I'm new to JSF and it 's not so simple.

So, how should the alghoritm of adding a new row look like?

RENDERER

1. get context

2. get component id

3. encode new row ?

JSP

actionListener = renderer.addNewRow(component id)

Thanks for any tips.

naked_ravena at 2007-7-14 19:32:46 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...