I must create a text file with ANSI encoding using vbs.
If I just create it, without to write any text, using this code...
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set ObjFileTxt = objFSO.objFSO.CreateTextFile("filename.txt", True, False)
Set ObjFileTxt = nothing
Set objFSO = nothing
... I get an ANSI text file, but if I try to write some text, for example...
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set ObjFileTxt = objFSO.CreateTextFile("filename.txt", True, False)
ObjFileTxt.Write "ok"
Set ObjFileTxt = nothing
Set objFSO = nothing
... I get an UTF8 text file.
Any help?