StringWriter.AppendBuffer (METH)¶
METHOD AppendBuffer : ERROR
AppendBuffer adds the passed buffer to the end of the current user data. The transfer takes place by reference and the specified free memory of this buffer is used for further use.
Note
Normally, buffers with a remaining length of 0 are transferred.
Otherwise the original buffer might be changed with further operations!

Schematic mode of operation¶
Tip
Larger constant character strings should be concatenate again and again by buffers.
1PROGRAM PLC_PRG
2VAR CONSTANT
3 c_wsLargeString : WSTRING(300) := 'Large information ...';
4END_VAR
5VAR
6 bfLargeString : SBM.Buffer := (pData := ADR(c_wsLargeString), udiSize := 300 * 2);
7 StringWriter : MSU.StringWriter;
8
9 ...
10END_VAR
11
12StringWriter.AppendBuffer(itfBuffer := bfLargeString, udiFreePageSize := 0);
13
14...
- InOut:
Scope
Name
Type
Comment
Return
AppendBuffer
Input
itfBuffer
SBM.IBuffer
udiFreePageSize
UDINT
Buffer to append