PeekS()

Syntax

Text$ = PeekS(*MemoryBuffer [, Length [, Flags]])
Description
For advanced programmers. Very useful to read a string at the specified memory address. The string should be ended by a '0' character, else it will read the memory until a '0' character is encounter.

An optional 'Length' parameter (in bytes) can be specified. If the 'Flags' parameter isn't specified, the string is reads as unicode if the program is compiled in unicode mode, else it's reads as ascii.

The optional 'Flags' parameter can 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 (the program can be either in unicode or ascii mode)
  #PB_Unicode: Reads the string as unicode, even when the program is compiled in ascii mode
When the 'Flags' parameter is specified, the 'Length' can be put to -1, to read the string until a null character is found.

Note: a combination of PokeS() and PeekS() can be used to perform conversion between the different supported string modes (Ascii, UTF8 and Unicode).

Supported OS

All

<- PeekQ() - Memory Index - PeekW() ->