VS:SubString/ja
Jump to navigation
Jump to search
.VectorScript|VectorScript ..VS:Function Reference|Function Reference ..VS:Function_Reference_Appendix|Appendix
Description
SubString はdelimiterの文字でtext文字列を分解し、index番目のトークンを返します。
最初のトークンは、1番である。
エラーの場合は、(空文字列)を返します。
indexが1より小さいか、トークン数よりも大きい場合、(空文字列)を返します。
FUNCTION SubString(
text :DYNARRAY[] of CHAR;
delimiter :STRING;
index :INTEGER) : DYNARRAY[] of CHAR;
def vs.SubString(text, delimiter, index): return DYNARRAY[] of CHAR
Parameters
text DYNARRAY[] of CHAR delimiter STRING index INTEGER
Example
middleStr:=SubString('Left;Middle;Right',';',2);
Version
Availability: from Vectorworks 2014