+ Reply to Thread
Results 1 to 5 of 5

Convert workbooks in a folder from xls to xlsx

  1. #1
    Forum Contributor
    Join Date
    10-03-2015
    Location
    North Carolina, USA
    MS-Off Ver
    Office 365
    Posts
    167

    Convert workbooks in a folder from xls to xlsx

    Hi,

    Can someone help with some code that goes through a folder of workbooks that are saved as xls files, and convert them to xlsx files?

    Thank you!

  2. #2
    Forum Expert
    Join Date
    10-06-2008
    Location
    Canada
    MS-Off Ver
    2007 / 2013
    Posts
    5,528

    Re: Convert workbooks in a folder from xls to xlsx

    Have a peak here.
    https://www.rondebruin.nl/win/s5/win001.htm

  3. #3
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,938

    Re: Convert workbooks in a folder from xls to xlsx

    There is no "code" to change the file types, you need top open each file, and Save As for the other file format (the code in the link above does that for you)
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  4. #4
    Forum Contributor
    Join Date
    10-03-2015
    Location
    North Carolina, USA
    MS-Off Ver
    Office 365
    Posts
    167

    Re: Convert workbooks in a folder from xls to xlsx

    Thank you, Jolivanes. I'm such a newb that I can't even make the code in the link you provided work for me. Ultimately, I don't even need to convert the file format. It would be nice, but not necessary.

    I have some code that loops through several workbooks in a folder, performs some actions, and then closes the workbooks. When the code closes the workbooks, I get the following message:

    Excel-Compatibility-Checker-Dialog.png

    Is there a way that I can suppress this message message from popping up for every file? If that is possible, then I really don't need to convert the files to the later file format.

    Edit: I think I found what I was looking for:

    ActiveWorkbook.CheckCompatibility = False
    ActiveWorkbook.CheckCompatibility = True
    Last edited by carlito2002wgn; 03-01-2019 at 03:41 PM.

  5. #5
    Forum Expert
    Join Date
    10-06-2008
    Location
    Canada
    MS-Off Ver
    2007 / 2013
    Posts
    5,528

    Re: Convert workbooks in a folder from xls to xlsx

    You could try
    Please Login or Register  to view this content.
    If you want to convert, this might be a solution for you.
    http://www.eileenslounge.com/viewtopic.php?f=27&t=27341
    Last edited by jolivanes; 03-01-2019 at 04:02 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. Convert csv files in folder to .xlsx not working
    By moosmahna in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-21-2018, 03:12 AM
  2. Help with code to convert xls to xlsx and continue with xlsx file
    By 3345james in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-02-2016, 11:47 AM
  3. Macro to Convert .csv info to .xlsx and save it in another folder under previous name
    By YogurtFace in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-10-2014, 07:14 PM
  4. Replies: 3
    Last Post: 01-05-2014, 05:50 AM
  5. Replies: 1
    Last Post: 12-10-2013, 12:11 PM
  6. How to add the columns data of several xlsx files of a folder in another xlsx file
    By ravikumar00008 in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 05-25-2012, 04:29 AM
  7. Convert Folder of Workbooks to TXT Files
    By dvent in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-17-2009, 06:00 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