BinaryStream.ReadPString Function

Reads a Pascal string from the stream and returns it as a String. The optional parameter Encoding enables you to specify the encoding to be defined on the returned string.

Syntax
result = BinaryStream.ReadPString( [Encoding] )

Parameters
Encoding | TextEncoding (Optional)

Return Value
Result | String

# Notes

Use the Encodings object to specify the text encoding. If you omit this parameter (or pass Nil), then the encoding of the returned string will be Nil.