You are here: PSPad forum > English discussion forum > How to force pspad to open a file with encoding UTF-8

How to force pspad to open a file with encoding UTF-8

#1 How to force pspad to open a file with encoding UTF-8

Posted by: torro | Date: 2015-09-09 14:43 | IP: IP Logged

Hi,

I have a bench of files and I want that pspad all files open with encoding UTF-8 no matter which encoding the files are.
I tried to set "Format" to UTF-8 doesn't help
I tried to set "Settings" "Program Setting" "Files and dir" "Default CP for files opening" to UTF-8
still opens files as ANSI.
Is it possible to force pspad to open the files in UTF-8?

Thanks a lot,

Torro

Options: Reply | Quote | Up ^


#2 Re: How to force pspad to open a file with encoding UTF-8

Posted by: pspad | Date: 2015-09-09 15:18 | IP: IP Logged

There is several reasons, why PSPad opens files as ANSI instead of UTF-8

1. there is no BOM and your UTF-8 doesn't contains any accented chars. In this case content of ANSI and UTF-8 is same - there are no chars encoded in UTF-8

2. file is encoded in UTF-8 but there are some errors (e.g. file contains non encoded chars). Typically exports from MySQL. In case you open this file as UTF-8, you will lost some chars.

To force PSPad open file as UTF-8:
open your file
in the format menu click to UTF-8 (click it even UTF-8 is selected)
Use reload file (Ctrl+R)

Options: Reply | Quote | Up ^


#3 Re: How to force pspad to open a file with encoding UTF-8

Posted by: torro | Date: 2015-09-09 15:34 | IP: IP Logged

Thanks a lot.
Yes, there is not a BOM. The files are php files.
And yes the files are coded in UTF-8, but have one or two signs which are not UTF-8 signs.

Unfortunately your procedure doesn't work (I followed the procedure carefully). The files still encoded wrong.

Options: Reply | Quote | Up ^


#4 Re: How to force pspad to open a file with encoding UTF-8

Posted by: pspad | Date: 2015-09-09 15:56 | IP: IP Logged

What PSpad version do you use? Can you test latest buld from PSPad developer forum?
Can you send me to support mail any of your file?

Options: Reply | Quote | Up ^


#5 Re: How to force pspad to open a file with encoding UTF-8

Posted by: torro | Date: 2015-09-09 16:15 | IP: IP Logged

Thanks a lot.

I used the 4.5.9. build 2600
now I tried build 2669 and it worked. So it is already solved.

Thanks a lot

Options: Reply | Quote | Up ^






Editor PSPad - freeware editor, © 2001 - 2024 Jan Fiala, Hosted by Webhosting TOJEONO.CZ, design by WebDesign PAY & SOFT, code Petr Dvořák, Privacy policy and GDPR