+ Reply to Thread
Results 1 to 5 of 5

Save File for Each Row

  1. #1
    Forum Contributor
    Join Date
    12-09-2015
    Location
    Virginia, USA
    MS-Off Ver
    Excel 365
    Posts
    129

    Save File for Each Row

    Hello, I'm hoping you guys can help me out with a macro that will save each row in Excel as a separate file. The filename will be the CellValue of Column 1 and the contents of the file will be the CellValue of Column2. The extension needs to be ".sps"

    I am just learning VBA through a lot of trial and error with recording macros, but this one has me seriously stuck!

    Example

    a1 001 b1: dog
    A2 022 b2: cat
    A3 051 b3: donkey
    A4 006 b4: moose

    file1 = "001.sps" and inside the document it would say "dog"

    Thanks!

    Ron

  2. #2
    Valued Forum Contributor
    Join Date
    11-26-2012
    Location
    Sydney
    MS-Off Ver
    2010
    Posts
    423

    Re: Save File for Each Row

    Try this:

    Please Login or Register  to view this content.

  3. #3
    Forum Expert
    Join Date
    12-14-2012
    Location
    London England
    MS-Off Ver
    MS 365 Office Suite.
    Posts
    8,448

    Re: Save File for Each Row

    As far as I can see, Excel cannot save as an sps file.

    However SPSS can open an xls file.

    BRB
    My General Rules if you want my help. Not aimed at any person in particular:

    1. Please Make Requests not demands, none of us get paid here.

    2. Check back on your post regularly. I will not return to a post after 4 days.
    If it is not important to you then it definitely is not important to me.

  4. #4
    Forum Expert
    Join Date
    12-14-2012
    Location
    London England
    MS-Off Ver
    MS 365 Office Suite.
    Posts
    8,448

    Re: Save File for Each Row

    As far as I can see, Excel cannot save as an sps file.

    However SPSS can open an xls file.

    BRB


    Please Login or Register  to view this content.
    Last edited by mehmetcik; 12-09-2015 at 08:30 PM.

  5. #5
    Forum Contributor
    Join Date
    12-09-2015
    Location
    Virginia, USA
    MS-Off Ver
    Excel 365
    Posts
    129

    Re: Save File for Each Row

    This was perfect. Thanks, MGS! You are a genius!!!

+ 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. save as which remains the master file and save new file
    By ash3angel in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 07-16-2015, 04:13 AM
  2. Macro needed to open "File Save As" and change save file type
    By blainerhett in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-28-2014, 02:40 PM
  3. Replies: 1
    Last Post: 09-05-2013, 02:39 PM
  4. Save as macro that specifies file type, file location and takes file name from three cells
    By ExcelFailure in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 06-13-2013, 10:09 PM
  5. Replies: 0
    Last Post: 01-27-2013, 12:13 PM
  6. How to: Open file, format data, save file, close file and repeat.
    By thexeber in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-11-2010, 12:56 PM
  7. [SOLVED] Excell2003 (SP-1) File > Save and File > Save As.. grayed out
    By Joe Murphy in forum Excel General
    Replies: 0
    Last Post: 03-09-2005, 06:06 PM

Tags for this Thread

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