No – because:
ActiveDocument is a Document.
CurrentDoc is a Document.
But ActiveName is a String.
The following will work (if "TargetFolder & "\" &
FNames(FNix)" is the full name of an existing document):
Dim CurrentDoc as Document
Set CurrentDoc = Application.Documents.Open(TargetFolder & "\" &
FNames(FNix), , False)
With CurrentDoc.PageSetup
.FooterDistance = InchesToPoints(0.5)
.BottomMargin = InchesToPoints(0.7)
End With
Tip: If you use the Option Explicit statement in all modules, it will help
you find errors in your code. See:
"Why variables should be declared properly" at:
http://www.word.mvps.org/FAQs/MacrosVBA/DeclareVariables.htm
--
Regards
Lene Fredborg
DocTools - Denmark
www.thedoctools.com
Document automation - add-ins, macros and templates for Microsoft Word