TextEncoding.Code

From Xojo Documentation

Revision as of 01:53, 30 July 2019 by Gperlman (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Read-Only Property (As Integer )
IntegerValue = aTextEncoding.Code

Supported for all project types and targets.

The Mac OS TextEncoding value, useful for Declares.

Notes

You can also use it to compare two encodings: If the Code properties of two TextEncoding objects are equal, then they represent the same text encoding (including base, variation, and format).

Sample Code

This code gets the value of Code for the text in TextArea1.

Var t As TextEncoding
t = Encoding(TextArea1.Value)
If t <> Nil Then
Label4.Value = t.Code.ToString
End If