Note PARTdesigner expressions can be used at different places (e.g. in the sketch or in dimensionings).
 IF THEN ELSE ENDIF VAL SIN(VAL) Sine VAL COS(VAL) Cosine VAL ASIN(VAL) Arc sine VAL ACOS(VAL) Arc cosine VAL TAN(VAL) Tangent VAL COT(VAL) Cotangent VAL ATAN(VAL) Arc tangent VAL CONTAINS(STR1,STR2) Check whether STR1 contains STR2: Result: 1, if yes; 0, if no. Example: ```CONTAINS("Sechskantschraube","schraube") = 1 CONTAINS(NENNX,"X") = 1``` Variables do not need quotation marks. Text does not have to be set into quotation marks. VAL SGN(VAL) Signum function The function assigns +1 for x > 0, 0 for x = 0 and -1 for < 0. Example: ```SGN(10) = 1 SGN(5) = 1 SGN(0) = 0 SGN(-10) = -1 SGN(-5) = -1``` STR TOK(STR,STR,VAL) TOK(string, separator, position of the searched value) Result: String of the searched position Example: `TOK("a,b,c,d,e,f",",",4) = d` VAL NTOK(STR,STR) NTOK(string, separator) Result: Number of string elements Example: `NTOK("a,b,c,d,e,f",",") = 6` STR QTOK(STR,STR,STR,VAL) QTOK(string, separator, sign of text identification, position of the searched value) Result: string of the searched position in quotation marks The expression is similar to TOK, but here the particular elements of the string are marked with a sign of text identification. Example: `TOK("<'a','b','c','d','e','f'",",","'",5) = "e"` VAL NQTOK(STR,STR,STR) NQTOK(string, separator, sign of text identification) Result: Number of string elements Example: `NQTOK("<'a','b','c','d','e','f'",",","'") = 6` VAL CVAL(STR) Transformation from type STRING to type DOUBLE STR CSTR(VAL) Transformation from type DOUBLE to type STRING VAL SQRT(VAL) Square root VAL ABS(VAL) Absolute value Example: `|-3.4| = 3.4` VAL CUT(VAL) Cutting the decimal places Example: `CUT(3.8) = 3` VAL RND(VAL) Round Example: ```RND(3.8) = 4 RND(1.4) = 1``` STR LCASE(STR) Transformation of all letters to lower case letters STR UCASE(STR) Transformation of all letters to upper case letters VAL INDEX(STR,STR) INDEX(string, searched part of string) Result: Position of part of the string Example: `INDEX("test","e")=2` STR MID(STR,VAL,VAL) MID(string,starting position,number of elements to cut out to the right) Example: `MID("test",2,2) = "es"` STR LEFT(STR,VAL) LEFT(string, number of elements to cut out from the left side) Example: `LEFT("test",2) = "te"` STR RIGHT(STR,VAL) RIGHT(string, number of elements to cut out from the right side) Example: `RIGTH("test",2) = "st"` VAL GETTHREADVALUE(STR,STR,VAL,STR) Compare the following function: GETTHREADTEXT gets a text from the table and GETTHREADVALUE a DOUBLE value. VAL GETTHREADTEXT(STR,STR,VAL,STR) Used with threads: Using the following expression you can generate different output. Example: `NAME = GETTHREADTEXT(D,'DIN 13','',P,'NAME')` A detailed description is found under Section 7.9.3.11.1.1.2, “Different pitches and derived automatic calculations for e.g. Row Label and Core diameter ”. VAL KFIX(VAL) Don't use, not supported! STR FORMATSTR(STR,STR) Don't use, not supported! STR FORMATVAL(STR,VAL) Don't use, not supported!