Board index » delphi » Searching the ListView

Searching the ListView

Can someone help me on this. Can you give me a sample code that when
searching for the string 'Agent' in a listview if the item is found make it
popup saying the Index of the item?
 

Re:Searching the ListView


Quote
Agent wrote:
> Can someone help me on this. Can you give me a sample code that when
> searching for the string 'Agent' in a listview if the item is found make it
> popup saying the Index of the item?

for i:=0 to listview.items.count-1 do
  if listview.items[i]='Agent' then
   showmessage(inttostr(i));

Hows that?
--
"If your art becomes pop you're just a dead clown" - the quote of many a {*word*99}
musician

Other Threads