ReplaceAll Method
ReplaceAll(String, String, out Int32)
When implemented by a class, replaces all occurrences of given text within class text content by specified replaceWith string.
Declaration
bool ReplaceAll(string text, string replaceWith, out int count)
Parameters
Type | Name | Description |
---|---|---|
String | text | Text to find. |
String | replaceWith | Text to replace. |
Int32 | count | Number of replaced occurrences. |
Returns
Type | Description |
---|---|
Boolean | True if succeed; otherwise false. |
ReplaceAll(String, String, SearchOptions, out Int32)
When implemented by a class, replaces all occurrences of given text within text content by specified replaceWith string.
Declaration
bool ReplaceAll(string text, string replaceWith, SearchOptions options, out int count)
Parameters
Type | Name | Description |
---|---|---|
String | text | Text to find. |
String | replaceWith | Text to replace. |
SearchOptions | options | Represents options to search text. |
Int32 | count | Number of replaced occurrences. |
Returns
Type | Description |
---|---|
Boolean | True if succeed; otherwise false. |
ReplaceAll(String, String, SearchOptions, Regex, out Int32)
When implemented by a class, replaces all occurrences of given text within class text content by specified replaceWith string.
Declaration
bool ReplaceAll(string text, string replaceWith, SearchOptions options, Regex expression, out int count)
Parameters
Type | Name | Description |
---|---|---|
String | text | Text to find. |
String | replaceWith | Text to replace. |
SearchOptions | options | Represents options to search text. |
Regex | expression | Represents a regular expression to find text. |
Int32 | count | Number of replaced occurrences. |
Returns
Type | Description |
---|---|
Boolean | True if succeed; otherwise false. |
ReplaceAll(String, String, SearchOptions, Regex, out Int32, out Boolean)
When implemented by a class, replaces all occurrences of given text within class text content by specified replaceWith string.
Declaration
bool ReplaceAll(string text, string replaceWith, SearchOptions options, Regex expression, out int count, out bool abort)
Parameters
Type | Name | Description |
---|---|---|
String | text | Text to find. |
String | replaceWith | Text to replace. |
SearchOptions | options | Represents options to search text. |
Regex | expression | Represents a regular expression to find text. |
Int32 | count | Number of replaced occurrences. |
Boolean | abort | Indicates whether replace action aborted. |
Returns
Type | Description |
---|---|
Boolean | True if succeed; otherwise false. |