Sorry for the delay in posting my code?I had to work on other things for awhile. Anyway, here?s the code as I revised it. I need to open a group of password protected files, but I don?t want to have to manually type in the password and unlock each one.
I want to modify the code so that all the files in the folder will open, the password will be applied to unlock each one of them, and all files are on screen and ready for me to type in.
[vba]Sub CheckMyDir()
Dim path As String
Dim strFile As String
Dim getFile
path = "C:\work\My Folder"
getFile = Dir(path & "*.dot")
Do While getFile <> ""
strFile = path & getFile
Documents.Open FileName:=strFile, passwordtemplate:="doccenter"
getFile = Dir
Loop
End Sub[/vba]
I'm totally sure it's me that's messed up the code!