Trims every item in the list and returns a new list.
listItemTrim(list [, delimiters] [, includeEmptyFields])
returns string
list.listItemTrim([delimiters] [, includeEmptyFields])
Name | Type | Required | Default | Description |
---|---|---|---|---|
list | string | Yes | The list with the items, you want to trim. | |
delimiters | string | No | , | The delimiters which the list is using. |
includeEmptyFields | boolean | No | false | By default empty items will be removed from the list. If it is true, empty items will be stay in the list. |
Trims each item in the list.
exampleList = "hello, world ,this, is a, ,example";
writeOutput(listItemTrim(examplelist));
Trims each item in the list.
exampleList = "hello, world ,this, is a, ,example";
exampleList = exampleList.listItemTrim();
writeOutput(examplelist);
Trims each item in the list and keep empty items.
exampleList = "hello, world ,this, is a, ,,example";
writeOutput(listItemTrim(examplelist, ",", true));