StringExtensionsReplace(String, Char) Method

Replace specified characters with an empty string.

Definition

Namespace: PCBI_CadanceFab_Import
Assembly: PCBI_CadanceFab_Import (in PCBI_CadanceFab_Import.dll) Version: 17.0.0.0 (17.0.0.0)
C#
public static string Replace(
	this string s,
	params char[] chars
)

Parameters

s  String
the string
chars  Char
list of characters to replace from the string

Return Value

String
System.string

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type String. 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).

Example

string s = "Friends"; s = s.Replace('F', 'r','i','s'); //s becomes 'end;

See Also