Das müsste sein, was du haben willst. Funktioniert natürlich nur, solange es richtig sortiert ist
AutoIt
$Gui=GUICreate("",400,400)
$TreeView=GUICtrlCreateTreeView(5,5,390,390)
$ar=FileReadToArray("Path.txt")
GUISetState()
local $ActualPath[10][2]
for $i=1 to UBound($ar)-1 step 1
$ar2=StringSplit($ar[$i],";",1+2)
local $j=0
for $j=0 to UBound($ActualPath)-1 step 1
if $j<>7 then
if $ar2[$j]<>$ActualPath[$j][0] then
ExitLoop
endif
endif
next
for $j=$j to UBound($ActualPath)-1 step 1
if $j<>7 then
$ActualPath[$j][0]=$ar2[$j]
if $j=0 then
$ActualPath[$j][1]=GUICtrlCreateTreeViewItem($ar2[$j],$TreeView)
else
$ActualPath[$j][1]=GUICtrlCreateTreeViewItem($ar2[$j],$ActualPath[(($j-1)<>7?($j-1):($j-2))][1])
endif
endif
next
next
while sleep(10)
if GUIGetMsg()=-3 then exit
WEnd
Alles anzeigen