TreeView的遍历
var
node: TTreeNode;
label ok;
begin
node := TreeView1.TopItem;
while True do
begin
if node.HasChildren then
node := node.GetFirstChild
else
begin
while node.IsLast do
if node.Level = 0 then
goto ok
else
node := node.Parent;
node := node.GetNextSibling;
end;
end;
ok:null; //结束
end;