+ Reply to Thread
Results 1 to 3 of 3

Import CSV Into Worksheet

  1. #1
    Registered User
    Join Date
    01-22-2014
    Location
    Oregon
    MS-Off Ver
    Excel 2010
    Posts
    29

    Import CSV Into Worksheet

    Good evening. I have searched the internet far and wide and have not found a solution to my problem. I am confident there is one out there, but I can't find it.

    I need a macro to do this:

    Open a '.csv' file. I will know the path the file is saved, but I do NOT know the file name. I need the macro to allow me to select the file from the path provided.
    Import the data from the '.csv' file to the 'mc' worksheet from the original workbook. The original workbook will always have the same filename if that is needed to activate it.
    Close the '.csv' file

    I am very thankful for any help provided.

    Matt

  2. #2
    Valued Forum Contributor ranman256's Avatar
    Join Date
    07-29-2012
    Location
    Kentucky
    MS-Off Ver
    Excel 2003
    Posts
    1,192

    Re: Import CSV Into Worksheet

    paste the code into a module,
    change the start path to yours: Const kDIR = "c:\temp\"
    then make a button to run: ImportCsv


    Please Login or Register  to view this content.

  3. #3
    Forum Expert
    Join Date
    10-11-2021
    Location
    Netherlands
    MS-Off Ver
    365
    Posts
    1,505

    Re: Import CSV Into Worksheet

    To keep it simple and to paste the CSV directly in sheet1 of your source file.
    Only change your folderpath in the macro below

    Please Login or Register  to view this content.
    Last edited by JEC.; 01-05-2022 at 01:03 PM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Import Worksheet From Another Workbook
    By dgarber in forum Excel General
    Replies: 3
    Last Post: 12-31-2018, 12:51 PM
  2. [SOLVED] Excel VBA Button: Import Data from other worksheet incl. selection of source worksheet
    By kingofcamden in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-26-2018, 04:07 AM
  3. Import worksheet and remove old worksheet references with find and replace
    By shawnvon in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-11-2015, 12:25 PM
  4. Import .csv file into a worksheet
    By polcen in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 11-05-2012, 08:38 PM
  5. Import a worksheet into an existing worksheet
    By manatee2000 in forum Excel General
    Replies: 4
    Last Post: 03-25-2011, 03:26 AM
  6. Macro to import an excel worksheet into a specific worksheet.
    By Bisboy in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 12-07-2010, 10:22 AM
  7. Import worksheet add-in?
    By l8sk8r in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-07-2008, 07:47 AM

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1