Results 1 to 7 of 7

Thread: [Resolved]Trouble with Listview Subitems

Threaded View

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Jul 2001
    Location
    Maumelle, AR
    Posts
    624

    [Resolved]Trouble with Listview Subitems

    I am sure I have totally screwed this up, but here is my code. I am trying to loop through a listview control, storing the listitems and all of the subitems.

    Code:
     Dim SurgProcedures(frmaddforms.lvSurgProcedures.items.count) as String
    
    
     Dim frm As frmAddForms
    
    
            With frm
    
                For i As Integer = 0 To frm.lvSurgProcedures.Items.Count - 1
    
                    SurgProcedures(i) = frm.lvSurgProcedures.Items.Item(i)
                   
                    SurgDate = frm.lvSurgProcedures.Items.Item(i).SubItems(0)
                    SurgName = frm.lvSurgProcedures.Items.Item(i).SubItems(1)
                    Surgphone= frm.lvSurgProcedures.Items.Item(i).SubItems(2)
                    SurgFacility = frm.lvSurgProcedures.Items.Item(i).SubItems(3)
                    SurgPostOp = frm.lvSurgProcedures.Items.Item(i).SubItems(4)
    
                Next
            End With
    I have SurgDate, SurgName, etc. declared as strings. Thanks in advance for any direction.
    Last edited by hipopony66; Feb 23rd, 2009 at 12:26 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width