Click or drag to resize

ReplaceTextConverterConvert Method (String, String, String, RegexOptions, Boolean)

Converts the specified value by replacing text using a regular expression.

Namespace:  TomsToolbox.Wpf.Converters
Assembly:  TomsToolbox.Wpf (in TomsToolbox.Wpf.dll)
Syntax
public static Object? Convert(
	string? value,
	string? pattern,
	string? replacement,
	RegexOptions options,
	bool replaceAll
)

Parameters

value
Type: SystemString
The value to convert.
pattern
Type: SystemString
The regular expression to find.
replacement
Type: SystemString
The replacing text.
options
Type: System.Text.RegularExpressionsRegexOptions
The options for the regular expression.
replaceAll
Type: SystemBoolean
if set to true all occurrences will be replaces; otherwise only the first.

Return Value

Type: Object
The converted value.
See Also