PerformLayout after adding new nodes

Below is a slimmed down version but has the relevant parts in a generic language. I create a diagram by calling RenderGraph and it works fine. If I call the method again it adds the nodes however it does not perform a new layout. The nodes are under or overlapping the current nodes. IS there something missing like invalidating existing or what not?

Func RenderGraph( DataTableofParentChild as Datatable)

    GoViewer.Dock = DockStyle.Fill
    Digraphlayout.Document = GoViewer.Document
     Loop Datatable DataTableofParentChild
                    nObjectNode =  New GoBasicNode
                    nDependentNode  = New GoBasicNode
                   AddLink(nObjectNode, nDependentNode)
    end Loop

end Func

Does RenderGraph completely replace the whole diagram each time, or do subsequent calls always just add more nodes and links?

The Loop is always going to create two nodes connected by a link. I don’t see how you get a tree or anything else you could layout with that.

Can you provide the full code for the layout?