I have used the treeview on a multipage userform see and modify the code as desired. I did not have a problem like you do. I had 3 treeviews.
Private Sub fill_in_treeview()
'Purpose: Populate the treeview control
Dim ws As Worksheet
Dim cl As Range
Dim sParentWH As String
Dim sParentPart As String
Dim sChildPart As String
Dim a As String
Dim u As MultiPage
Set u = MultiPage1
UserForm2.MultiPage1.Value = 2
a = UserForm2.MultiPage1(0).TextBox2.Value
UserForm2.MultiPage1(2).TextBox20.Value = a
On Error GoTo error1
With Me
.TreeView1.Sorted = False
.TreeView1.LineStyle = tvwRootLines
With Me.TreeView1.Nodes
'Clear TreeView control
.Clear
For Each cl In Worksheets("Prod_Struct").Range("A3:A20000")
'Add parent WH if necessary
If cl.Value = sParentWH Then
'same parent, ignore
Else
sParentWH = cl.Value
.Add , sParentWH, sParentWH, sParentWH
End If
'Add parent Part # if necessary
If cl.Offset(0, 1).Value = sParentPart Then
'same parent, ignore
Else
sParentPart = cl.Offset(0, 1).Value
.Add relative:=sParentWH, _
relationship:=tvwChild, _
Key:=sParentWH & "-" & sParentPart, _
Text:=sParentPart
End If
'Add child Part and quantity
If cl.Offset(0, 3).Value = sChildPart Then
'same child, ignore
Else
sChildPart = cl.Offset(0, 3).Value
.Add relative:=sParentWH & "-" & sParentPart, _
relationship:=tvwChild, _
Key:=sParentWH & "-" & sParentPart & "-" & sChildPart, _
Text:=sChildPart
.Add relative:=sParentWH & "-" & sParentPart & "-" & sChildPart, _
relationship:=tvwChild, _
Key:=sParentWH & "-" & sParentPart & "-" & sChildPart & "-Quantity", _
Text:="Quantity= " & cl.Offset(0, 4).Value
End If
Next cl
End With
End With
error1:
End Sub