+ Reply to Thread
Results 1 to 4 of 4

Newbie: How should I run same commands on multiple .CSV files

  1. #1
    Registered User
    Join Date
    09-07-2011
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    27

    Newbie: How should I run same commands on multiple .CSV files

    I have a few .CSV files I would like to do some filtering, sorting, consolidating on, and then outputting onto a new sheet or Book. There are a few files I would like to do this on, so I would like to learn a process I can repeat.

    I know how to program in C++ and was just going to parse the whole .CSV file and use arrays, but I would like to use excel so it looks nice and organized.

    Can anyone give me some keywords I should google to do this? Macros? VB?

    Thanks for any help.

  2. #2
    Forum Expert
    Join Date
    10-09-2014
    Location
    Newcastle, England
    MS-Off Ver
    2003 & 2013
    Posts
    1,986

    Re: Newbie: How should I run same commands on multiple .CSV files

    Theres a few threads on here for dealing with files in VBA and loads about multiple files.

    Heres one I can think of > http://www.excelforum.com/excel-prog...ml#post3902766

    Also if you google "VBA file handling" and "VBA cycle files" should give you some hints & tips

    The basis of your requirement though would be to write a macro that does what you want for one file (you may be able to do this by recording the macro) then when you've got that doing what you want, amend it to bring in the filename via a variable and find one of the many file handling loops to pull files from a directory, get their name and pass it to the macro.
    Last edited by pjwhitfield; 12-08-2014 at 02:20 PM.
    If someone has helped you then please add to their Reputation

  3. #3
    Registered User
    Join Date
    09-07-2011
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    27

    Re: Newbie: How should I run same commands on multiple .CSV files

    Got it. Thank you.

    I'm already working on writing the macro. Using Record macro to do some basic syntax discover and google if the syntax doesn't look robust enough.

    Thanks again.

  4. #4
    Forum Expert
    Join Date
    10-09-2014
    Location
    Newcastle, England
    MS-Off Ver
    2003 & 2013
    Posts
    1,986

    Re: Newbie: How should I run same commands on multiple .CSV files

    No worries, any further issues/queries just post them

+ 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. [SOLVED] Newbie: Auto Updating database Files ?
    By luckyali in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 04-27-2014, 07:05 PM
  2. Macro Recording Chart Format commands missing all important commands!!!!
    By nounours in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-05-2013, 09:20 PM
  3. Replies: 2
    Last Post: 03-01-2012, 09:38 AM
  4. If / then type of commands in VB -- help for a newbie!
    By erosenzweig in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 02-15-2011, 10:39 AM
  5. Newbie... Macro - Importing multiple csv files to excel
    By dugong in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-24-2006, 05:04 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