IMPORTANT ANNOUNCEMENT

These forums will be permanently set to read-only mode on July 18, 2022. From that day on, no new posting or comment will be allowed on the site, but the historical content will remain intact and searchable.

A new location for posting questions about PlanetPress Suite is now available:

OL Learn - PlanetPress Classic (opens in new tab)

Topic Options
#58137 - 09/06/21 05:27 AM 2 Special Char being converted to the same Chars
Stephen O'Leary Offline
OL Newbie

Registered: 10/13/20
Posts: 8
Hi All,

I've got an XML data file which contains the special char Á that I want to replace with A. However, when I load the data file into the PlanetPress emulator it converts this special char to á. Unfortunately if you replace á with A this is not a solution because the problem is the data file contains another Special char Í which I want to replace with I. However, PlanetPress also converts I to the same 2 special chars i.e. á. Which means when á is replaced with A it also converts every occurrence of Í to A which is obviously not a solution. Has anyone seen anything like this before?

Any help would be appreciated.

Thanks,
Stephen

Top
#58138 - 09/06/21 05:49 AM Re: 2 Special Char being converted to the same Chars [Re: Stephen O'Leary]
MartenM Offline
OL Newbie

Registered: 10/15/20
Posts: 5
Hi Stephen,

Can you please explain what you mean by "PlanetPress emulator"? I suppose that you're referring to the emulation options when you select a input file as data sample via Debug > Select, is that correct? If so, can you let us know please which options you're using by Data Encoding and Emulations the moment you select a XML file as data sample? I'm asking you this because an option is to replace each Á character with a A character by making use of the Search and Replace plugin. But I suppose that this depends on the selected Data Encoding option.

Top
#58139 - 09/06/21 06:06 AM Re: 2 Special Char being converted to the same Chars [Re: Stephen O'Leary]
Stephen O'Leary Offline
OL Newbie

Registered: 10/13/20
Posts: 8
Hi MartenM,

That's correct by "PlanetPress emulator" I'm referring to the emulation options when you select a input file as data sample via Debug > Select.

The Data Encoding and Emulations are as follows:

Data Encoding: Microsoft Windows Codepage 1252 (Latin 1)

Emulation: XML

Emulation options: Cache XMl data checkbox is unchecked.

Thanks,
Stephen

Top
#58140 - 09/06/21 06:45 AM Re: 2 Special Char being converted to the same Chars [Re: Stephen O'Leary]
Stephen O'Leary Offline
OL Newbie

Registered: 10/13/20
Posts: 8
Apologies MartenM,

When originally posting this problem I've pasted in the wrong character. The offending char is à not á which is the problem. Just to recap on the example both special char Á and special char Í are both being converted to special char à by Planetpress.

Top
#58141 - 09/08/21 07:59 AM Re: 2 Special Char being converted to the same Chars [Re: Stephen O'Leary]
MartenM Offline
OL Newbie

Registered: 10/15/20
Posts: 5
Hi Stephen,

Can you please explain which issue you're currently facing? If I understand you correctly is that the current issue is that both the characters "Á" and "Í" are both being converted to the character "Ã" but that you would like to replace the characters "á" ("Ã" plus "¡") with the character "A". Is this correct? Or would you like to replace the characters "ÁÍ" ("Á" plus "Í") with the character "A"?

Can you also let us know what the encoding is of your XML file?

Top
#58142 - 09/08/21 10:08 AM Re: 2 Special Char being converted to the same Chars [Re: Stephen O'Leary]
Yannick Fortin Offline
OL Expert

Registered: 08/25/00
Posts: 354
Loc: Objectif Lune Montréal
Your XML file is encoded in UTF-8. Hence, any non-ASCII character will be written as two, perhaps three, bytes.

In particular, "Á" and "Í" are encoded as 0xC3 0x81 and 0xC3 0x8D respectively. To a non-Unicode application like Workflow, this would look like "Ã" followed by a space... or no space, since 0x81 and 0x8D are undefined in Windows 1252.

I would suggest that you use Notepad++, more specifically the Encoding menu, to figure out which byte combination matches which character.

You could also convert your XML file to an encoding supported by Workflow, such as Windows 1252, using the Translator plugin and then process your file.
_________________________
Yannick Fortin, Team OL

Top