CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    May 2005
    Location
    Leeds, England
    Posts
    3

    Help with ReadLine method

    Hi guys, could someone point me in the right direction please?

    I have 2 list boxes, the first one (lstFullFileContents) contains all lines within a specific file.

    I would then like to extract a certain line, in this case always line 5 from that list box to another (lstListBox1)...

    Getting lstFullFileContents to show all the lines isn't hard,

    Dim line As String
    line = sr.ReadLine()
    lstFileFullContents(line)

    I thought there would be a copy command I could use maybe... but the only one I could find copies the whole list box contents...

    Any ideas please?

    Many thanks.

  2. #2
    Join Date
    Dec 2002
    Posts
    305

    Re: Help with ReadLine method

    lstListBox1.items.add(lstFileFullContents.items.item(4))

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

Featured