VCFilter::CanMove Method (Object^)
Visual Studio 2015
Returns true if the filter can be moved to the specified location.
Assembly: Microsoft.VisualStudio.VCProjectEngine (in Microsoft.VisualStudio.VCProjectEngine.dll)
Parameters
- Parent
-
Type:
System::Object^
Required. The folder or project into which you want to move the filter.
Return Value
Type: System::Booleantrue if the filter can be moved to the specified location; otherwise, false.
See How to: Compile Example Code for Project Model Extensibility for information about how to compile and run this example.
The following example uses CanMove in the integrated development environment (IDE):
' Macro code. ' add reference to Microsoft.VisualStudio.VCProjectEngine Imports EnvDTE Imports Microsoft.VisualStudio.VCProjectEngine Public Module Module1 Sub Test() Dim mycollection As IVCCollection Dim filter, filter2 As VCFilter Dim prj As VCProject Dim ret As Boolean prj = DTE.Solution.Projects.Item(1).Object mycollection = prj.Filters 'mycollection.Count has count of files filter = mycollection.Item(1) filter2 = mycollection.Item(2) ret = filter.CanMove(filter2) MsgBox(ret) End Sub End Module
Show: