DTE2.ActiveSolutionProjects 属性

定义

获取当前选定项目的数组。

public:
 property System::Object ^ ActiveSolutionProjects { System::Object ^ get(); };
public:
 property Platform::Object ^ ActiveSolutionProjects { Platform::Object ^ get(); };
[System.Runtime.InteropServices.DispId(237)]
public object ActiveSolutionProjects { [System.Runtime.InteropServices.DispId(237)] get; }
[<System.Runtime.InteropServices.DispId(237)>]
[<get: System.Runtime.InteropServices.DispId(237)>]
member this.ActiveSolutionProjects : obj
Public ReadOnly Property ActiveSolutionProjects As Object

属性值

Object

当前选定项目的数组。

实现

属性

示例

Sub ActiveSolutionProjectsExample()  
  Dim projs As System.Array  
  Dim proj As Project  
  projs = DTE2.ActiveSolutionProjects()  
  If projs.Length > 0 Then  
    proj = CType(projs.GetValue(0), EnvDTE.Project)  
    MsgBox(proj.UniqueName)  
  Else  
    MsgBox(projs.Length)  
  End If  
End Sub  

适用于