View Single Post
  #3   Report Post  
Posted to microsoft.public.word.docmanagement
Graham Mayor Graham Mayor is offline
external usenet poster
 
Posts: 19,312
Default Default prompt for password

The following in an autonew macro in the document template will work, but I
would urge caution.

Dim sPassword As String
sPassword = InputBox("Enter password for this document", "Password")
With ActiveDocument
.Password = sPassword
.WritePassword = sPassword
End With
MsgBox "The password for this document is " & sPassword & vbCr & _
"If you forget the password you will not be able to open the document"


--

Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org


Kokomojo wrote:
I'm wondering if it's possible in Word 2003/2002 to set a default
that will prompt the user to create a password (for editing and/or
opening) for each new document created.

Thanks!