Skip to content
Martin Danielsson edited this page Dec 16, 2024 · 2 revisions

Returns the index of a substring. Much like the IndexOf method of a string.

What Type
Syntax IndexOf(a, b)
a string
b string
Return type int

Example

<CustomOperator name="RemoveArrow" paramCount="1" returnType="string">
  <Parameters>
    <Parameter name="input" type="string" />
  </Parameters>
  <Switch>
    <Case condition='Contains(%input, " -&gt; ")'>Trim(Substring(%input, Add(IndexOf(%input, "-&gt;"), 2), Length(%input)))</Case>
    <Otherwise>%input</Otherwise>
  </Switch>
</CustomOperator>
Clone this wiki locally