TListView is not "really" column oriented, only row oriented. Now having said that, each row is an "Item".
The data in the first column is in Item.Caption The data in the second column is in Item.SubItems[0] The data in the third column is in Item.SubItems[1] ... Just because one row has 5 columns of data does not mean that another does. That is what you use Item.SubItems.Count for. For me, I just make sure their are all the columns before I use contstant indexes - while Item.Subitems < "num of cols -1" do Item.SubItems.Append("some default value'); Then I can use Item.SubItems[ some constant ] with out worrying Doug On 3/28/2010 7:12 AM, c80840 wrote: > I'm still fairly new to DELPHI, but I'm working on my second project. I just > ran into something that I need help with. Here is the setup. > > 1. A string processing variable called "as_cell_value". > 2. I have a TListView called LV. > 3. LV has 4 rows and 2 columns. Let's say the data looks like this: > > +------+-----+-----+ > | |col1 |col2 | > +------+-----+-----+ > | row1 | c11 | c21 | > +------+-----+-----+ > | row2 | c12 | c22 | > +------+-----+-----+ > | row3 | c13 | c23 | > +------+-----+-----+ > | row4 | c14 | c24 | > +------+-----+-----+ > > 4. I need to get the data out of each cell in column 2 in turn, place it > into the variable, and process it. > > I'm having problems fining out how to do that. Can someone help me? Once I > get it into the variable, I'll be OK from there. > > Thanks loads to all. > > > > > > ------------------------------------ > > ----------------------------------------------------- > Home page: http://groups.yahoo.com/group/delphi-en/ > To unsubscribe: delphi-en-unsubscr...@yahoogroups.comyahoo! Groups Links > > > > > > > > No virus found in this incoming message. > Checked by AVG - www.avg.com > Version: 9.0.791 / Virus Database: 271.1.1/2774 - Release Date: 03/27/10 > 13:32:00 > > [Non-text portions of this message have been removed]