Click to See Complete Forum and Search --> : ListView


VortexLrd
February 11th, 2000, 05:48 PM
I'm trying to get access to a 'syslistview32' like those in a FILE/OPEN dialog... I need to get let's say the 3rd item of the 3rd column. When I try to send different API SendMessage calls, it just closes the application (example notepad) with no errors or anything. I tried with an LVITEM (sendmessage hwnd, 3, 3, theLVITEM) and such, without success... Anybody can help me with this? I only need to get some TEXT from a LISTVIEW control of another program... Thank you in advance, I really really really need this ...

Johnny101
February 15th, 2000, 01:51 PM
If you're are just looking to get the value then the following should work:

MsgBox ListView1.ListItems(index).SubItems(subIndex)




You can see from this how you could loop through the entire collection.

If the user is selecting an item, you might be able to use:

MsgBox ListView1.SelectedItem.SubItems(subIndex)




Hope this helps,
John

John Pirkey
MCSD
www.ShallowWaterSystems.com