How to convert a txt file with ANSI coding to utf-8 without BOM

Hi guys,

Anyone knows if I can convert the coding of a txt file? I mean convert, not coding:

if I code to utf-8 without BOM, I get some wrong characters. Instead of this, if I convert to utf-8 without BOM it works. So basically I need to read a txt and then convert it with that coding.

I’ve read something about doing this with Powershell activity but never did before and really don’t know how to do it.

Thank you guys

Hi @Pablo_Sanchez

This thread might be useful:

The Write Text activity also has the Encoding parameter that you can use. You might need to experiment a bit with the correct encoding, but it should work :slight_smile:


Hi @loginerror, actually I’ve resolved that issue using Powershell activity.

If someone needs to know what I’ve done, I can explain it with some screenshots with a few comments. Easy to understand.


1 Like

Okey, I’ve got a like, so gonna explain it:

In my case, after doing this I had to read again the output .txt, so in the reading, UiPath changes the encoding again, so I had to put the encoding that I want, and make again the previous steps:

So doing this, I fixed the problem that UiPath coulnd’t write well some characters like “ñ” or “á,í,ó,ú,é”

Hope it could help someone. Some like would be awesome :wink: .