Retrieves a substring from this instance. The substring starts at a specified
character position.
Namespace: MonoSoftware.CoreAssembly: MonoSoftware.Core (in MonoSoftware.Core.dll) Version: 1.0.40.669 (1.0.40.669)
Syntax
C# |
---|
public static string Substring(
this StringBuilder sb,
int startIndex
) |
Visual Basic |
---|
<ExtensionAttribute>
Public Shared Function Substring (
sb As StringBuilder,
startIndex As Integer
) As String |
Visual C++ |
---|
public:
[ExtensionAttribute]
static String^ Substring(
StringBuilder^ sb,
int startIndex
) |
F# |
---|
static member Substring :
sb : StringBuilder *
startIndex : int -> string
|
Return Value
Type:
StringA System.String equivalent to the substring of length length that begins
at startIndex in this instance, or System.String.Empty if startIndex is equal
to the length of this instance and length is zero.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
StringBuilder. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
See Also