请问如何得到listbox控件中被选中的那一行?(10分)

T

tjlys

Unregistered / Unconfirmed
GUEST, unregistred user!
请问如何得到listbox控件中被选中的那一行?
 
var
i: Integer;
begin
i := ListBox1.ItemIndex;
Button1.Caption := IntToStr(i);
end;
 
单选:
showmessage(ListBox1.Items[ListBox1.ItemIndex]);
 
接收答案
谢谢各位[:D]
 
顶部