Name: sysSTREXT

Type: Function

Return value: USINT

Language type:

Description:

Extract a string anticipate by a separator character or <CR> in a text line terminated by <CR><LF><NULL> in a given position. The function return a USINT which could have the following meanings: 0 = String extracted correctly. 255 = String extracted truncated. 254 = Position not present. 253 = No <CR><LF><NULL> at the end of scanned string. 252 = String to be scanned too long.

Input:

Name Type Description
pos USINT Position [1...255]
msg_in STRING String to scan
sep BYTE ASCII code of the separator character
msg_ext STRING String extracted
len USINT SIZEOF(String extracted)