MindFusion.Wpf Pack Programmer's Guide
MID

Returns the specified number of characters from the specified text, starting at the specified position.

Syntax  Copy Code

MID( Text text, Integer start, Integer length )  Text

Parameters

text
Required. The string containing the characters that should be returned.
start
Required. The position of the first character to return. The first character in the text has position 1.
length
Required. The number of characters to return.

Remarks

If start is less than or equal to 0, the function returns the #VALUE! error value. If start is greater than the number of characters in text, an empty string is returned. If length is negative, the function returns #VALUE!. If length specifies more characters than available, the function returns all characters from start to the end of text. If length is zero, an empty string is returned.

If start or length are not integer values, they are automatically truncated.

Example

Formula  Copy Code

=MID(A2,1,5)
=MID("Quick brown fox",7,5)

See Also

Function Reference
LEFT Function
LEN Function
RIGHT Function
REPLACE Function
SUBSTITUTE Function
FIND Function
SEARCH Function