Document.HasPassword Property (2007 System)

Gets a value that indicates whether a password is required to open the document.

Namespace:  Microsoft.Office.Tools.Word
Assembly:  Microsoft.Office.Tools.Word.v9.0 (in Microsoft.Office.Tools.Word.v9.0.dll)

Syntax

'Declaration
Public ReadOnly Property HasPassword As Boolean
'Usage
Dim instance As Document 
Dim value As Boolean 

value = instance.HasPassword
public bool HasPassword { get; }
public:
property bool HasPassword {
    bool get ();
}
public function get HasPassword () : boolean

Property Value

Type: System.Boolean
true if a password is required to open the document; otherwise, false.

.NET Framework Security

See Also

Reference

Document Class

Document Members

Microsoft.Office.Tools.Word Namespace

Password

WritePassword