You need to sign in to do that
Don't have an account?
Dipika
dynamically add apex:repeat
hello,
I am creating a tree view on my vf page in which i dont know levels of tree. can anyone tell how can i add
dynamic apex:repeat in my vf page for levels of tree?
Hi,
If you want to create a tree view on the Vf page by using the <apex:repeat>.You can use the repeat with in repeat tag.
You can create a wrapper class controller and bind the controller list of wrapper class instenace to the repeat.
For Example:
<apex: repeat value=”{!mainclass}” var =”mainclassobj”>
{! mainclassobj .name}
<apex: repeat value=”{! mainclassobj }” var =”subclass”>
{! subclass .name}
</apex: repeat>
</apex: repeat>
Create the level of the tree by using nested repeats.
Did this answer your question? If not, let me know what didn't work, or if so, please mark it solved.
but if i dont know my levels of tree. then i want toadd apex:repeat dynamically. is there any way to do it?
You could dynamically add a repeat (or dynamically build the tree) using the dynamic components feature in Spring 2012. A pilot version is in the current release, but you would need to get approval to use it. Spring 2012 is coming soon.
Details are in the developer guide.