Powershell get encoding of file

A serializing XML file a string. The output file will be encrypted in ANSI (what is correct) run the Follow command in PowerShell Core (6. If we are using PowerShell version 6. Encoding] :: ASCII) shows how to specify a custom encoding if the string is not in coding of the Unicode text. ................
................