[string]$StringToEncode="編碼的字串"
$EncodedString=[Convert]::ToBase64String([System.Text.Encoding]::UTF8.GetBytes($StringToEncode))
write-host "Encoded String:" $EncodedString
$DecodedString=[System.Text.Encoding]::UTF8.GetString([System.Convert]::FromBase64String($EncodedString))
write-host "Decoded String:" $DecodedString