UnescapeString()

Syntax

Result$ = UnescapeString(String$ [, Mode])
Description
Returns the unescaped version of the string. EscapeString()() can be used to do the reverse operation.

Parameters

String$ The string to unescape.
Mode (optional) The mode to use when unescaping the string.
  #PB_String_EscapeInternal: unescape the string using PureBasic internal format (see General rules
                             for accepted escape sequences) (default).
  #PB_String_EscapeXML     : unescape the string using the XML escape characters. This can be useful to easily read any string from an
                             XML tree.

Return value

An unescaped string.

Example

  Debug UnescapeString(~"Test=\"Hello\".") ; Will display "Test="Hello"."
  Debug UnescapeString("&lt;item&gt;Hello&lt;/item&gt;", #PB_String_EscapeXML) ; Will display "<item>Hello</item>"

See Also

EscapeString()

Supported OS

All

<- UTF8() - String Index - Val() ->