Raised before closing the project. It deletes the supplied project from the references of other projects within the solution, if it is found.
Namespace: Microsoft.VisualStudio.Package
Assembly: MPF.Project.NonShipping (in MPF.Project.NonShipping.dll)
Syntax
'宣言
Public Overrides Function OnBeforeCloseProject ( _
hierarchy As IVsHierarchy, _
removed As Integer _
) As Integer
'使用
Dim instance As SolutionListenerForProjectReferenceUpdate
Dim hierarchy As IVsHierarchy
Dim removed As Integer
Dim returnValue As Integer
returnValue = instance.OnBeforeCloseProject(hierarchy, _
removed)
public override int OnBeforeCloseProject(
IVsHierarchy hierarchy,
int removed
)
public:
virtual int OnBeforeCloseProject(
IVsHierarchy^ hierarchy,
int removed
) override
public override function OnBeforeCloseProject(
hierarchy : IVsHierarchy,
removed : int
) : int
Parameters
hierarchy
Type: Microsoft.VisualStudio.Shell.Interop.IVsHierarchyThe project being closed.
removed
Type: System.Int32If 0, do not remove this project from project references; otherwise remove it.
Return Value
Type: System.Int32
S_OK.
Implements
IVsSolutionEvents3.OnBeforeCloseProject(IVsHierarchy, Int32)
IVsSolutionEvents2.OnBeforeCloseProject(IVsHierarchy, Int32)
IVsSolutionEvents.OnBeforeCloseProject(IVsHierarchy, Int32)
Permissions
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.
See Also
Reference
SolutionListenerForProjectReferenceUpdate Class