var
I :integer ;
begin
for I := 0 to ListBox1.Items .count-1do
begin
if ListBox1.Selected[i] then
if ListBox2.Items.IndexOf (ListBox1.items[i])<0 then
ListBox2.Items.Add (ListBox1.items[i]);
end ;
end;
I :integer ;
begin
for I := 0 to ListBox1.Items .count-1do
begin
if ListBox1.Selected[i] then
if ListBox2.Items.IndexOf (ListBox1.items[i])<0 then
ListBox2.Items.Add (ListBox1.items[i]);
end ;
end;
for i:=0 to n do
begin
if listbox2.items[2]=listbox1.items[listbox1.itemindex] then
break;
if i=n then
listbox2.items.add('string');
end;