Try changing:
If Right(strName, 4) = ".doc" Or Right(strName, 4) = ".dot" Then
to:
If Split(strName, ".")(UBound(Split(strName, "."))) Like "do[ct]*" Then
PS: When posting code, please use the code tags, inserted via the # button on the posting menu
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
|