INDEX Function [Visio 2003 SDK Documentation]
Returns the substring at the zero-based location index in the list delimited by delimiter. Or, it returns -1 if not found.
INDEX(index,"list"[,[delimiter][,[errorvalue]]])
index The location that you want to find.
list The list in which you want to search.
delimiter The string to use as a delimiter within list. A delimiter string can be more than one character in length and include multibyte characters. The default is a semicolon.
errorvalue Optional. A user-specified value to return if the index is out of range. The default is an empty string.
Remarks
If the list begins or ends with a delimiter, a null string is assumed to exist before or after the list. Consecutive delimiters imply a null string in between.
If the index is out of range, Visio returns an empty string or the optional token provided as the errorvalue argument.
Example 1
INDEX(3,"cat;rat;;goat")
Returns "goat".
Example 2
INDEX(54,";1;2;3;",,"ERROR")
Returns "ERROR."