FFWinPlugin.ViewDocument3

Applies to: SharePoint Foundation 2010

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

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

Parameters

expression

An expression that returns an FFWinPlugin object.

pdisp

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

bstrDocumentLocation

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

OpenType

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

Value

Description

0

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

1

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

2

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

4

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

varProgID

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

Return Value

true if the document was successfully opened; otherwise, false.

See Also

Reference

OpenDocuments.ViewDocument3 Method