Excerpt |
---|
Returns a NamedStyle object that represents the named style that has the specified string version of its name. |
Signature |
---|
C# | C# | Wiki Markup |
---|
{description}
{excerpt}Returns a [NamedStyle|NamedStyle] object that represents the named style that has the specified string version of its name.{excerpt}
{signature:C#}
public NamedStyle this[System.String name] { get; }
|
Signature |
---|
{signature}{signature:vb.net | vb.net | }
Public Default ReadOnly Property Item(ByVal name As String) As NamedStyle
|
...
An String
that represents the name of the style's name to retrieve.
Returns |
---|
A NamedStyle object that represents the named style that has the specified string version of its name or the specified index. |
Example |
---|
Code Block |
---|
| csharp | csharp |
title | C# |
---|
{signature}
{parameters}
{param:name}An {{String}} that represents the name of the style's name to retrieve.{param}
{returns}A {{NamedStyle}} object that represents the named style that has the specified string version of its name or the specified index.{returns}
{example}{code:csharp|title=C#}
//--- Get Style by name
NamedStyle myStyle = styls["MyStyle"];
//--- Get Style by ID
NamedStyle styleZero = styls[0];
Code Block |
---|
{code}
{code:vb.net
vb.net | title | |title=vb.net
}
'--- Get Style by name
Dim myStyle As NamedStyle = styls.Item("MyStyle")
'--- Get Style by ID
Dim styleZero As NamedStyle = styls.Item(0)
{code}
{example}