Agar OK tugmasi bosilmagan bo‘lsa protseduradan chiqiladi:
if not InputQuery(...) then
exit;
Keyingi qator yangi element qo‘shadi:
NewNode:=TreeViewl.Items.Add(TreeViewl.Selected, CaptionStr);
TreeViewl komponentasining
Items xossasida hamma elementlar