HtmlTextWriter.WriteEncodedText Method (String)
Encodes the specified text for the requesting device, and then writes it to the output stream.
Assembly: System.Web (in System.Web.dll)
Use themethod when a string contains angle brackets (< or >) or an ampersand (&).
The HtmlEncode method to perform the encoding and also converts Unicode character 00A0 to .method uses the
The following code example shows how to use the <custID> & <invoice#> to the output stream. The WriteBreak method writes <br />.method to write the encoded markup
Available since 2.0