View Single Post
 
Old 07-07-2017, 07:07 AM
AHKpie AHKpie is offline Windows 7 64bit Office 2010 64bit
Novice
 
Join Date: Jun 2017
Posts: 7
AHKpie is on a distinguished road
Default

I solved my problem of not working macro by simplyfing Paul Edsteins script into this:
Code:
Sub Simplify()
Dim file
Dim path As String


'YOU MUST EDIT THIS. Put here the files you want to change with your macro.
path = "c:\test\"


file = Dir(path & "*.*")
Do While file <> ""
Documents.Open FileName:=path & file

' This is the call to the macro you want to run on each file in the folder
Call Macro2

' Saves the file
ActiveDocument.Save
ActiveDocument.Close
' set file to next in Dir
file = Dir()
Loop
End Sub
Reply With Quote