Skip to main content
darkoj
Known Participant
Jan 24, 2022 4:30 PM UTC
Question

An invalid XML character (Unicode: 0x1a) was found

Hi to everyone!

Can everyone help me with this error message? I guess that PDF can't be created because of some special character?

ERROR:
An invalid XML character (Unicode: 0x1a) was found in the element content of the document

Thanks!

3 replies

gopalk2865
Participating Frequently
Jan 25, 2022 4:13 AM UTC

Hi darkoj, Looks like some characters are not being recognized while using pdf converter, You will have to find out which characters in your docx are not being recognized and replacing them with supported characters will resolve the issue.

darkoj
darkojAuthor
Known Participant
Jan 25, 2022 2:15 PM UTC

Yes, that's true. I found in the customer name some characters that can't be recognized by PDF converter.
Bad data quality. 
Do you have some advice on how to solve this? Except for manually customer name change directly in DB. Thanks

agamb0001
Participating Frequently
Jan 25, 2022 2:34 PM UTC

Hi Darko

use clean function to clean data before sending it to PDF 

Eg: try running below in a rule. It cleans any characters not considered printable

clean("Hello ╜ world")