How to create a macro on a Mac that opens and does a SavesAs on all files in a folder?

Anonymous
2023-01-18T01:39:42+00:00

I have several hundred Word files that need to be opened, saved in .odt format, then re-opened and saved in .docx (This eliminates an error message I get every time I open the files). I have very limited experience coding in VBA, so I am not sure how to structure the macro. I would be grateful for your help in automating this process through the use of a macro.

Thank you.

Microsoft 365 and Office | Word | For home | MacOS

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

16 answers

Sort by: Newest
  1. Doug Robbins - MVP - Office Apps and Services 323.6K Reputation points MVP Volunteer Moderator
    2023-01-20T19:53:40+00:00

    You can turn off alerts by using

      Application.DisplayAlerts = wdAlertsNone 
    

    You should later use

     Application.DisplayAlerts = wdAlertsAll 
    

    to turn them back on.

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2023-01-20T19:44:09+00:00

    Thank you! Do I need an overwrite command on the second macro?

    Was this answer helpful?

    0 comments No comments
  3. Deleted

    This answer has been deleted due to a violation of our Code of Conduct. The answer was manually reported or identified through automated detection before action was taken. Please refer to our Code of Conduct for more information.


    Comments have been turned off. Learn more

  4. Anonymous
    2023-01-20T06:09:36+00:00

    Yes. I was able to get it to work on my Mac as well. Thank you!

    Now I need to complete the full process by adding more to the macro.

    I need it to save .docx files as .odt. Then, save them back again to .docx files (This will get rid of an error message I have opening older MSWord files) Can I do all of that in this same macro? Or do I need to run 2 macros to accomplish this?

    Thank you,

    Chip

    Was this answer helpful?

    0 comments No comments
  5. Anonymous
    2023-01-20T05:50:34+00:00

    Here is my test result.

    Was this answer helpful?

    0 comments No comments