Skip to main content
Visual Studio SDK
IVsShellIsPackageLoaded Method

Determines whether a VSPackage identified by the package GUID (guidPackage) is loaded in the environment.

Namespace:   Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)
Syntax
Function IsPackageLoaded ( _
	ByRef guidPackage As [%$TOPIC/bb140633_en-us_VS_120_1_0_0_0_0%], _
	<[%$TOPIC/bb140633_en-us_VS_120_1_0_0_0_1%]> ByRef ppPackage As [%$TOPIC/bb140633_en-us_VS_120_1_0_0_0_2%] _
) As [%$TOPIC/bb140633_en-us_VS_120_1_0_0_0_3%]
[%$TOPIC/bb140633_en-us_VS_120_1_0_1_0_0%] IsPackageLoaded(
	ref [%$TOPIC/bb140633_en-us_VS_120_1_0_1_0_1%] guidPackage,
	out [%$TOPIC/bb140633_en-us_VS_120_1_0_1_0_2%] ppPackage
)
[%$TOPIC/bb140633_en-us_VS_120_1_0_2_0_0%] IsPackageLoaded(
	[[%$TOPIC/bb140633_en-us_VS_120_1_0_2_0_1%]] [%$TOPIC/bb140633_en-us_VS_120_1_0_2_0_2%]% guidPackage, 
	[[%$TOPIC/bb140633_en-us_VS_120_1_0_2_0_3%]] [%$TOPIC/bb140633_en-us_VS_120_1_0_2_0_4%]^% ppPackage
)
abstract IsPackageLoaded : 
        guidPackage:[%$TOPIC/bb140633_en-us_VS_120_1_0_3_0_0%] byref * 
        ppPackage:[%$TOPIC/bb140633_en-us_VS_120_1_0_3_0_1%] byref -> [%$TOPIC/bb140633_en-us_VS_120_1_0_3_0_2%]
function IsPackageLoaded(
	guidPackage : [%$TOPIC/bb140633_en-us_VS_120_1_0_4_0_0%], 
	ppPackage : [%$TOPIC/bb140633_en-us_VS_120_1_0_4_0_1%]
) : [%$TOPIC/bb140633_en-us_VS_120_1_0_4_0_2%]

Parameters

guidPackage
Type: SystemGuid

[in] GUID identifying a specific VSPackage.

ppPackage
Type: Microsoft.VisualStudio.Shell.InteropIVsPackage

[out] Pointer to a pointer to a package object.

Return Value

Type: SystemInt32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.
Remarks

COM Signature

From vsshell.idl:

HRESULT IVsShell::IsPackageLoaded(

   [in] REFGUID guidPackage,

   [out, retval] IVsPackage **ppPackage

);

.NET Framework Security