Partager via


IVsSolution2.GetProjectOfGuid Method (Guid%, IVsHierarchy%)

Returns the project in the solution, given a unique identifier.

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

Syntax

'Déclaration
Function GetProjectOfGuid ( _
    ByRef rguidProjectID As Guid, _
    <OutAttribute> ByRef ppHierarchy As IVsHierarchy _
) As Integer
'Utilisation
Dim instance As IVsSolution2
Dim rguidProjectID As Guid
Dim ppHierarchy As IVsHierarchy
Dim returnValue As Integer

returnValue = instance.GetProjectOfGuid(rguidProjectID, _
    ppHierarchy)
int GetProjectOfGuid(
    ref Guid rguidProjectID,
    out IVsHierarchy ppHierarchy
)
int GetProjectOfGuid(
    [InAttribute] Guid% rguidProjectID, 
    [OutAttribute] IVsHierarchy^% ppHierarchy
)
abstract GetProjectOfGuid : 
        rguidProjectID:Guid byref * 
        ppHierarchy:IVsHierarchy byref -> int 
function GetProjectOfGuid(
    rguidProjectID : Guid, 
    ppHierarchy : IVsHierarchy
) : int

Parameters

  • rguidProjectID
    Type: System.Guid%
    [in] Unique identifier (GUID) for the project.

Return Value

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

Implements

IVsSolution.GetProjectOfGuid(Guid%, IVsHierarchy%)

Remarks

COM Signature

From vsshell.idl:

HRESULT IVsSolution2::GetProjectOfGuid(
   [in] REFGUID rguidProjectID, 
   [out] IVsHierarchy **ppHierarchy
);

The project is identified by the GUID. This method returns the IVsHierarchy interface for the project based on the specified GUID.

.NET Framework Security

See Also

Reference

IVsSolution2 Interface

IVsSolution2 Members

GetProjectOfGuid Overload

Microsoft.VisualStudio.Shell.Interop Namespace