B4X Requires Chilkat v11.2.0+
B4X
Base62 Encoding and Decoding
Demonstrates base62 encoding and decoding.Chilkat B4X Downloads
Dim bd As ChilkatBinData
bd.Initialize
' Base62 encode.
bd.AppendString("hello world", "utf-8")
Dim base62_encoded As String = bd.GetEncoded("base62")
Log("hello world --> " & base62_encoded)
' Output:
' hello world --> AAwf93rvy4aWQVw
' Base62 decode
Dim sb As ChilkatStringBuilder
sb.Initialize
sb.DecodeAndAppend("AAwf93rvy4aWQVw", "base62", "utf-8")
Log("decoded: " & sb.GetAsString)
' Output:
' decoded: hello world