Hinweis
Für den Zugriff auf diese Seite ist eine Autorisierung erforderlich. Sie können versuchen, sich anzumelden oder das Verzeichnis zu wechseln.
Für den Zugriff auf diese Seite ist eine Autorisierung erforderlich. Sie können versuchen, das Verzeichnis zu wechseln.
Gets whether a node is selected.
Namespace: EnvDTE
Assembly: EnvDTE (in EnvDTE.dll)
Syntax
'Declaration
ReadOnly Property IsSelected As Boolean
bool IsSelected { get; }
property bool IsSelected {
bool get ();
}
abstract IsSelected : bool with get
function get IsSelected () : boolean
Property Value
Type: System.Boolean
A Boolean value indicating true if the item is selected, false otherwise.
Examples
Sub IsSelectedExample()
Dim UIH As UIHierarchy = _
DTE.Windows.Item(Constants.vsWindowKindMacroExplorer).Object
Dim UIHItem As UIHierarchyItem = UIH.GetItem("Macros\Samples")
UIHItem.Select(vsUISelectionType.vsUISelectionTypeSetCaret)
If UIHItem.IsSelected = False Then
If UIH.UIHierarchyItems.Expanded = True Then
MsgBox("Node is expanded.")
Else
MsgBox("Node is not expanded.")
End If
End If
UIH.SelectDown(vsUISelectionType.vsUISelectionTypeSelect, 2)
UIH.DoDefaultAction()
UIH.SelectDown(vsUISelectionType.vsUISelectionTypeSelect, 1)
UIH.SelectUp(vsUISelectionType.vsUISelectionTypeExtend, 1)
End Sub
.NET Framework Security
- 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.