- If you do not apply a to a capturing group, the <xref:System.Text.RegularExpressions.Group.Captures%2A?displayProperty=nameWithType> property returns a <xref:System.Text.RegularExpressions.CaptureCollection> with a single <xref:System.Text.RegularExpressions.Capture> object that provides information about the same capture as the <xref:System.Text.RegularExpressions.Group> object. If you do apply a quantifier to a capturing group, the `Group.Index`, `Group.Length`, and `Group.Value` properties provide information only about the last captured group, whereas the <xref:System.Text.RegularExpressions.Capture> objects in the <xref:System.Text.RegularExpressions.CaptureCollection> provide information about all subexpression captures. The example provides an illustration.
0 commit comments