Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Sub ProtectDocuments()
On Error Goto ErrHandler
Dim dlgSelect As FileDialog
Set dlgSelect = Application.FileDialog(msoFileDialogFolderPicker)
dlgSelect.Show
With Application.FileSearch
.FileType = msoFileTypeWordDocuments
.LookIn = dlgSelect
.Execute
For I = 1 To .FoundFiles.Count
Set myDoc = Documents
myDoc.Open FileName:=dlgSelect & "\" & myDoc
myDoc.Password = strPassword
myDoc.Close
Next I
End With
Exit Sub
ErrHandler:
MsgBox Err.Description
Exit Sub
End Sub