一个listbox4里有3条记录,用户全选了 复制到 listbox2 里 为何只复制了2条记录? 如下代码 For i:=1 to ListBox1.Items.Count do
begin
if ListBox1.Selected[i] then
begin
ListBox2.Items.Add(ListBox1.Items.Strings[i]);
end;
//i:=1;
end;
begin
if ListBox1.Selected[i] then
begin
ListBox2.Items.Add(ListBox1.Items.Strings[i]);
end;
//i:=1;
end;
//
For i:=0 to ListBox1.Items.Count-1 do