StringToArray_v2 Op

StringToArray

Parse a string into an array (create, split string, stringToArray)


Let’s you enter multiple values as an array in the editor. The result can then be used by e.g. Ops.Array.ArrayGetValue.


Full Name
  • Ops.Array.StringToArray_v2
Visibility
  • Core Op - Official cables op
License
  • MIT
AuthorgithubTest Patches


Example Patch Array Sum

Open In Editor

Youtube Video Tutorial

INPUT PORTS


text (String)

The array-data you want to use, e.g. 100,200,300

separator (String)

The separator to use, e.g. , (comma) when your text is foo,bar,baz

Numbers (Number:boolean )

If set, the values inside the array will be interpreted as numbers (not strings)

Trim (Number:boolean )
Split Lines (Number:boolean )

OUTPUT PORTS


array (Array)

The parsed array

Parsed (Trigger)

Triggers once the array has been parsed

length (Number)

The number of elements in the resulting array


Patches using StringToArray_v2

  • Examples
  • Public
  • My Patches

Changelog


enhancement: ignore comma after last valueuser avatarpandur - 2019-08-26 11:57
renameOps.Array.ParseArray_v2 renamed to Ops.Array.StringToArray_v2user avatarpandur - 2023-06-05 12:01