Results 1 to 2 of 2

Thread: Dir list box and file list box help needed

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Jun 2006
    Posts
    218

    Dir list box and file list box help needed

    Dim results As String, dummy As String
    Dim Endpart As String
    Dim datapath As String
    datapath = "C:\data\171916\data"
    ' open the text file
    Open App.Path & "\resultscash.txt" For Output As #1

    ' start searching the folder for any csv files
    results = Dir(datapath & "\*.csv")


    this code reads all the .csv files from the C:\data\171916\data

    what i wan to do is to add a Dir list box so that i can select the data path variable and then want to display all the csv files in a file list so that i will be able to select which files i want to read and then process

    in short the datapath's value should be the value of Dir list box and instead of where im using *.csv it should be the files which i choose from the file list box

  2. #2
    Hyperactive Member
    Join Date
    Dec 2006
    Location
    Jar, Norway
    Posts
    372

    Re: Dir list box and file list box help needed


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