Freigeben über


ColorableItems.Name-Eigenschaft

Legt den Namen des ColorableItems-Objekts fest oder ruft diesen ab.

Namespace:  EnvDTE
Assembly:  EnvDTE (in EnvDTE.dll)

Syntax

'Declaration
ReadOnly Default Property Name As String
string this { get; }
property String^ default {
    String^ get ();
}
abstract Name : string with get
function get Name () : String

Eigenschaftswert

Typ: String
Eine Zeichenfolge, die den Namen des ColorableItems-Objekts darstellt.

Beispiele

Sub ColorableItemsExample()
   Dim props As EnvDTE.Properties
   props = DTE.Properties("FontsAndColors", "TextEditor")
   Dim prop As EnvDTE.Property = props.Item("FontsAndColorsItems")
   Dim clritems As EnvDTE.FontsAndColorsItems = prop.Object
   Dim clritem As EnvDTE.ColorableItems
   Dim ClrList As String
   For Each clritem In clritems
      ClrList += clritem.Name + " (" + clritem.Foreground.ToString() + ")"
      ClrList += Chr(13) & Chr(10)
   Next
   MsgBox(ClrList)
End Sub

.NET Framework-Sicherheit

Siehe auch

Referenz

ColorableItems Schnittstelle

EnvDTE-Namespace

Weitere Ressourcen

Gewusst wie: Kompilieren und Ausführen der Codebeispiele für das Automatisierungsobjektmodell