VB.NET
VB.NET
HTML Entity Encode and Decode in StringBuilder
Demonstrates HTML encoding and decoding the contents of a StringBuilder.Chilkat VB.NET Downloads
Dim sb As New Chilkat.StringBuilder
Dim s As String = "< é ü ç Ω Hello & World ✓ >"
sb.Append(s)
sb.Encode("html","utf-8")
Debug.WriteLine(sb.GetAsString())
' Output:
' < é ü ç Ω Hello & World ✓ >
' To decode:
sb.Decode("html","utf-8")
Debug.WriteLine(sb.GetAsString())
' Output:
' < é ü ç Ω Hello & World ✓ >