View Single Post
 
Old 07-04-2018, 09:08 PM
gmayor's Avatar
gmayor gmayor is offline Windows 10 Office 2016
Expert
 
Join Date: Aug 2014
Posts: 4,138
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

Change
Code:
Dim FSO As FileSystemObject
to

Code:
Dim FSO as Object

Change
Code:
Set FSO = New FileSystemObject
to

Code:
Set FSO = CreateObject("Scripting.FileSystemObject")

Note you have some undeclared variables in use and some declared variables that are not used.
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote