Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]
Enables access to a member of the collection by string index.
Namespace: System.Text.RegularExpressions
Assembly: System.Text.RegularExpressions (in System.Text.RegularExpressions.dll)
Syntax
'Declaration
Public ReadOnly Property Item ( _
groupname As String _
) As Group
public Group this[
string groupname
] { get; }
public:
property Group^ Item[String^ groupname] {
Group^ get (String^ groupname);
}
member Item :
groupname:string -> Group with get
JScript does not support indexed properties.
Parameters
- groupname
Type: System. . :: . .String
The name of a capturing group.
Property Value
Type: System.Text.RegularExpressions. . :: . .Group
The member of the collection specified by groupname.
Remarks
groupName can be either the name of a capturing group that is defined by the (?<name>) element in a regular expression, or the string representation of the number of a capturing group that is defined by a grouping construct. For more information about groups in regular expressions, see Grouping Constructs.
If groupname is not the name of a capturing group in the collection, or if groupname is the name of a capturing group that has not been matched in the input string, the method returns a Group object whose Group..::..Success property is false and whose Group.Value property is String..::..Empty.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see dd66cd4c-b087-415f-9c3e-94e3a1835f74.