Sample code for 30+ languages & platforms
PowerBuilder

StringBuilder EntityDecode

Demonstrates the Chilkat StringBuilder EntityDecode method to decode HTML entities.

Chilkat PowerBuilder Downloads

PowerBuilder
integer li_rc
string s
oleobject loo_Sb

// Decode the following HTML entities, replacing each with the character represented.
s = "é é é Latin small letter e with acute"

loo_Sb = create oleobject
li_rc = loo_Sb.ConnectToNewObject("Chilkat.StringBuilder")
if li_rc < 0 then
    destroy loo_Sb
    MessageBox("Error","Connecting to COM object failed")
    return
end if

loo_Sb.Append(s)
loo_Sb.EntityDecode()

// Output: é é é Latin small letter e with acute
Write-Debug loo_Sb.GetAsString()


destroy loo_Sb