Basically you have to populate the parent level and then implement the OnTreeNodePopulate event. You might create the mark-up as:
<asp:TreeView
ID="tvRPM"
runat="server"
ClientIDMode="Static"
EnableClientScript="true"
ExpandDepth="0"
PopulateNodesFromClient="true"
ShowLines="true"
OnTreeNodePopulate="PopulateNode"
OnSelectedNodeChanged="tvRPM_SelectedNodeChanged">
<NodeStyle ForeColor="Black" HorizontalPadding="3" VerticalPadding="3" />
<HoverNodeStyle BackColor="#ffffcc" />
<SelectedNodeStyle BackColor="#dddddd" BorderColor="DarkGray" BorderStyle="Dotted" BorderWidth="1" HorizontalPadding="5" VerticalPadding="3" />
</asp:TreeView>
and have a method that populates the parents on load. then , within the PopulateNode method you would create and populate the childnodes passing the unique id of the parent as a key.
The method signature of PopulateNode looks like:
protected void PopulateNode(Object sender, TreeNodeEventArgs e)
I leave it to you to research the means by which you populate each new node from this point. Note that there are several articles on CP that outline this process in detail: search for those first.