Results 1 to 4 of 4

Thread: Need help with exporting {RESOLVED}

  1. #1

    Thread Starter
    Banned
    Join Date
    Jul 2005
    Posts
    63

    Resolved Need help with exporting {RESOLVED}

    Hi all,

    Im trying to export a list to a notepad file but am not sure where to start.

    Any help is appreciated.

    edit- The list i am trying to export is created via a search using vb6

    Thanks in advance,

    Atribune/Dave
    Last edited by Hack; Jul 19th, 2005 at 11:42 AM.

  2. #2
    PowerPoster lintz's Avatar
    Join Date
    Mar 2003
    Location
    The 19th Hole
    Posts
    2,697

    Re: Need help with exporting

    I presumed you meant a listbox??

    VB Code:
    1. Private Sub Command1_Click()
    2. Dim i As Integer
    3.  
    4. Open "C:\Export.txt" For Output As #1
    5.  
    6. For i = 0 To List1.ListCount - 1
    7. Print #1, List1.List(i)
    8. Next
    9.  
    10. Close #1
    11. End Sub
    12.  
    13. Private Sub Form_Load()
    14. List1.AddItem "This"
    15. List1.AddItem "is"
    16. List1.AddItem "a"
    17. List1.AddItem "test"
    18.  
    19. End Sub

  3. #3
    Hyperactive Member
    Join Date
    Jan 2003
    Location
    The Netherlands
    Posts
    386

    Re: Need help with exporting

    I take it that you are getting your search data in strings?
    if so, then Open an output file, and print the strings...


    VB Code:
    1. Open "\output.txt" for Output as #1
    2. Print #1, searchstring
    3. Close #1

  4. #4

    Thread Starter
    Banned
    Join Date
    Jul 2005
    Posts
    63

    Re: Need help with exporting

    Worked perfect thank you vey much Lintz

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