Hi,

I am trying to display records from a database in the form of a tree. The
Parent must have unlimitted children and the childrens, children must also
have unlimitted children.

The table looks like this.

ID (Autonumber - unique)
Name (text)
ParentID(Number) // if this number is a 0 then it is a parent record

some records:
ID NAME ParentID
1 Parent 0
2 1st child 1
3 1st childs child 2
4 1st childs 2nd child 2


What is the best way to display this records in a treeview look without
using a control.
<ol>
<li>Parent</li>
<ol>
<li>child</li>
</ol>
</ol>
The loop could be endless.

Thanks,

Aaron