MidText('Text','StartPos','Lenght=100000')

Arguments

'Text'

Text signal or "text" from where characters should be returned

'StartPos'

Analog signal or number; specifies the start position for the reading in the text.

Counting starts at zero (0 = 1st character).

'Length'

Analog signal or number; specifies the number of characters to be read,

Default=100000

Description

This function reads and returns 'Length' characters from a text beginning with the character at position 'StartPos'. If 'Length' is not specified, all characters from 'StartPos' until the end will be read.

Example

A standardized order number (text) contains always at the 6th position a four-digit customer code. This customer code should be read out.

Arguments

'Text'

'StartPos'

'Length'

[TextSignal_Order]

Value: 4711_ACME_1234XYZ

5

4

Formula

MidText([TextSignal_Order],5,4)

Result

ACME