IVsUIShellOpenDocument.IsDocumentInAProject Method

Determines whether a document is part of the project.

Namespace:  Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)

Syntax

‘선언
Function IsDocumentInAProject ( _
    pszMkDocument As String, _
    <OutAttribute> ByRef ppUIH As IVsUIHierarchy, _
    <OutAttribute> ByRef pitemid As UInteger, _
    <OutAttribute> ByRef ppSP As IServiceProvider, _
    <OutAttribute> ByRef pDocInProj As Integer _
) As Integer
‘사용 방법
Dim instance As IVsUIShellOpenDocument
Dim pszMkDocument As String
Dim ppUIH As IVsUIHierarchy
Dim pitemid As UInteger
Dim ppSP As IServiceProvider
Dim pDocInProj As Integer
Dim returnValue As Integer

returnValue = instance.IsDocumentInAProject(pszMkDocument, _
    ppUIH, pitemid, ppSP, pDocInProj)
int IsDocumentInAProject(
    string pszMkDocument,
    out IVsUIHierarchy ppUIH,
    out uint pitemid,
    out IServiceProvider ppSP,
    out int pDocInProj
)
int IsDocumentInAProject(
    [InAttribute] String^ pszMkDocument, 
    [OutAttribute] IVsUIHierarchy^% ppUIH, 
    [OutAttribute] unsigned int% pitemid, 
    [OutAttribute] IServiceProvider^% ppSP, 
    [OutAttribute] int% pDocInProj
)
abstract IsDocumentInAProject : 
        pszMkDocument:string * 
        ppUIH:IVsUIHierarchy byref * 
        pitemid:uint32 byref * 
        ppSP:IServiceProvider byref * 
        pDocInProj:int byref -> int 
function IsDocumentInAProject(
    pszMkDocument : String, 
    ppUIH : IVsUIHierarchy, 
    pitemid : uint, 
    ppSP : IServiceProvider, 
    pDocInProj : int
) : int

Parameters

  • pszMkDocument
    Type: System.String
    [in] String form of the unique moniker identifier of the document in the project system, for example, the full path to the file. In non-file cases, this identifier is often in the form of a URL.
  • pitemid
    Type: System.UInt32%
    [out] Pointer to the hierarchy item identifier of the document in the project system. For more information see VSITEMID.
  • pDocInProj
    Type: System.Int32%
    [out, retval] Flags that indicate whether a document is part of a project. For more information, see __VSDOCINPROJECT.

Return Value

Type: System.Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Remarks

COM Signature

From vsshell.idl:

HRESULT IVsUIShellOpenDocument::IsDocumentInAProject(
   [in] LPCOLESTR pszMkDocument,
   [out] IVsUIHierarchy **ppUIH,
   [out] VSITEMID *pitemid,
   [out] IServiceProvider **ppSP,
   [out, retval] VSDOCINPROJECT *pDocInProj
);

.NET Framework Security

See Also

Reference

IVsUIShellOpenDocument Interface

IVsUIShellOpenDocument Members

Microsoft.VisualStudio.Shell.Interop Namespace