AdvCheckedTreeView

Can you provide me with an example of how to load an AdvCheckedTreeView with a table like this:
ID, DETALLE, PARENT
1, NUEVO, -1
2, SEGUNDO, 1
3, TERECERO, 2
4, CUARTO, -1
5, AAAAAAAAB, -1
6, sesto, -1
7, spt, 6
8, octa, -1
9, nove, 3
10, decimo, 3
11, once, 5
12, doce, 11
13, trece, 10

I can't find the way, I must be able to check the parent node and have the children change their status too

Gracias

var
  p1, p2: TAdvTreeViewNode;
begin
  AdvTreeView1.Clear;

  AdvTreeView1.BeginUpdate;
  AdvTreeView1.Columns.Add.Text := 'ID';
  AdvTreeView1.Columns.Add.Text := 'DETAILLE';

  p1 := AdvTreeView1.AddNode();
  p1.Text[0] := '1';
  p1.Text[1] := 'NUEVO';

  p2 := AdvTreeView1.AddNode(p1);
  p2.Text[0] := '2';
  p2.Text[1] := 'SEGUNDO';
  AdvTreeView1.EndUpdate;
end;

image

Hello, thanks for answering. I understand that example is the one in the help, but if I have to do them from a Query and go through it and generate the parent and child nodes, how do I do it.
the records some have children and grandchildren as I generate it.
So send a table structure that can have many records.
Gracias

Typically this is done in a recursive loop where you pass the parent as a parameter to the function. Unfortunately we cannot provide a full worked out example in this case, there are too many parameters required and we'll have to have access to the data. If you want this, we can offer custom consulting. Please contact us by email for further followup.