This version is out of date, covering development from v9.0.0 to v9.3.0. It is maintained here only for inbound reference links from elsewhere. It is no longer actively updated.

Jump to the current version of aTbRef

Tinderbox v9 Icon

String.deleteCharacters("characterSet")


Operator Type: 

Operator Scope of Action: 

Operator Purpose: 

Operator First Added: 

Operator Altered: 

 Function   [other Function type actions]

 Item   [operators of similar scope]

 Data manipulation   [other Data manipulation operators]

 9.0.0

 


String.deleteCharacters("characterSet")

Returns a copy of the string from which all instances of every discrete character in the quoted literal string characterSet have been removed. For example:, if $MyString is "1Hello1 2world3";

$MyStringA = $MyString.deleteCharacters("1234567890"); 

would remove any digits from the target string, thus $MyStringA will be "Hello world", having removed two instances of '1', and a single instance of '2' and of '3'.

But were $MyString "Hello world: 45";

$MyStringA = $MyString.deleteCharacters("1234567890"); 

the result would be "Hello world: ". Importantly, note the trailing space as only the digits (i.e. characters in characterSet) have been removed.



A Tinderbox Reference File : Actions & Rules : Operators : Full Operator List : String.deleteCharacters("characterSet")