Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
OpenDocuments.ViewDocument3 Method

OpenDocuments.ViewDocument3 Method

Last modified: July 10, 2008

Applies to: SharePoint Foundation 2010

Opens the document for reading instead of editing, so that the document is not locked on the server in a specified window, and with a specified type.

expression.ViewDocument3(pdisp As Object, bstrDocumentLocation As String, OpenType As Long, varProgID)


An expression that returns an OpenDocuments Control object.


An Object that represents the window from which the ViewDocmument3 method is being activated.


A string that contains the URL of the document to open for reading.


A Long integer that specifies the rights for opening the document. The following table shows possible values.




When checked out, or when the document library does not require check out, the user can read or edit the document.


When another user has checked it out, the user can only read the document.


When the current user has checked it out, the user can only edit the document.


When the document is not checked out and the document library requires that documents be checked out to be edited, the user can only read the document, or check it out and edit it.


When the current user has checked it out, the user can only edit the local copy of the document.


An optional string that contains the ProgID of the application with which to open the document. If this argument is omitted, the default viewer for the document is used.

true if the document was successfully opened; otherwise false.

© 2015 Microsoft