ReadString()
Syntax
Text$ = ReadString(#File [, Flags])Description
Read a string from the #File until an 'End Of Line' character is found (Unix and DOS file formats are supported). Without any 'Flags', the string is reads as UTF8 if the program is compiled in unicode mode, else it's reads as ASCII.
The optional 'Flags' parameter may be one of the following values:#PB_Ascii : Reads the string as ASCII, even when the program is compiled in unicode mode #PB_UTF8 : Reads the string as UTF8, even when the program is compiled in ASCII mode #PB_Unicode: Reads the string as UTF16 (the program may be either in unicode or ASCII mode).For an example see the ReadFile() function.
For detecting the string encoding format (byte order mark) used in a file there is the ReadStringFormat() function available.
Supported OS
All