Hello Matthias ,
 
Thanks a lot, I will try it using your complete example. I will post here the result of my tests :-)
 
Johnny

Matthias Wessendorf <[EMAIL PROTECTED]> escribió:
there is a TreeNodeChecked clazz ([1]) for use case like this.

I used it this way:

JSP:
...
varNodeToggler="t" var="node">







...



...


Backing Bean (constructor or init() in case of Shale's ViewControler)
(btw. AnalysisFolder is an business object of me...)

-------------------------

tree = new TreeNodeBase("root","Analyses",false);

for (Iterator iter = listOfAnalysisFolders.iterator(); iter.hasNext();) {
AnalysisFolder element = (AnalysisFolder) iter.next();
tree.getChildren().add(
new TreeNodeChecked("analysisFolder", element.getName(),
element.getId(), false, true));
selectedIds.add(new SelectItem(element.getId()));
}


-------------------------


action method:

-------------------------

public String processNodes(){
List childs = tree.getChildren();
for (Iterator iter = childs.iterator(); iter.hasNext();) {
TreeNodeChecked element = (TreeNodeChecked) iter.next();
if(element.isChecked()==true) {
//do...
}
}
...
}
-------------------------

HTH,
Matthias

[1] http://tinyurl.com/eknbk

On 7/25/06, Johnny Gonzalez <[EMAIL PROTECTED]>wrote:
> Hello everybody,
>
> Can someone give me some guidance or just point me to a tutorial or any
> document, that explains how to create a checkboxTree? I have sucessfully
> worked with a tree2, but I need to create a similar tree but with check
> boxes on each leaf.
>
> I would appreciate any help. Thanks a lot,
>
> Johnny
>
>
> ________________________________
>
> LLama Gratis a cualquier PC del Mundo.
> Llamadas a fijos y móviles desde 1 céntimo por minuto.
> http://es.voice.yahoo.com
>
>


--
Matthias Wessendorf

further stuff:
blog: http://jroller.com/page/mwessendorf
mail: mwessendorf-at-gmail-dot-com



LLama Gratis a cualquier PC del Mundo.
Llamadas a fijos y móviles desde 1 céntimo por minuto.
http://es.voice.yahoo.com

Reply via email to