Copy link to clipboard
Copied
Hello community!
I hope that you can help me with an error I can't understand. I have two different PDF files, but created in the same way. One of them gets a character encoding error on a Heading Level 2 where there is a number in the text, but not the other one.
The one with the error is called landskronaweb.pdf and the one that passes Acrobat accessibility check is lommaweb.pdf.
I would appriciate any input of what the difference is between the files because I can't find it.
Thanks!
Copy link to clipboard
Copied
There are indeed some weird characters around that "1" in the title, namely:
LANDSKRONA NO \uDBC1\uDC2E Axelro,
They don't appear to be valid Unicode characters, hence the error you're getting. This is an issue with the library that created the PDF, most likely.
Copy link to clipboard
Copied
Not directly. I used a script I wrote to print out all the text, including any hidden characters, and then it showed up. Something similar you can do, though, is to copy that text and then paste it into a plain-text editor and you'll see the "1" appears as a square symbol.
Yes, "CeTe DynamicPDF" is the library/application that needs to be checked for a solution to this issue. Another option can be the font that was used ("Bitter Pro"). Maybe it has the wrong encoding for this character... You can try using a different font and see if the issue still happens.
Copy link to clipboard
Copied
Where do you see this error message, exactly?
Copy link to clipboard
Copied
When I run the Accessibility check in Acrobat, I get two errors on that file and the marker highlights the number in the Heading. I took a screenshot of the error and attach it here so you can see, it's in the Swedish version of Acrobat but "Teckenkodning" is Character Encoding.
Copy link to clipboard
Copied
There are indeed some weird characters around that "1" in the title, namely:
LANDSKRONA NO \uDBC1\uDC2E Axelro,
They don't appear to be valid Unicode characters, hence the error you're getting. This is an issue with the library that created the PDF, most likely.
Copy link to clipboard
Copied
Thank you! I appriciate it so much!! I hade no idea that you could see that in a PDF, can you see the unvalid characters in Acrobat?
I have created the files with CeTe DynamicPDF, is that what you mean by library?
Copy link to clipboard
Copied
Not directly. I used a script I wrote to print out all the text, including any hidden characters, and then it showed up. Something similar you can do, though, is to copy that text and then paste it into a plain-text editor and you'll see the "1" appears as a square symbol.
Yes, "CeTe DynamicPDF" is the library/application that needs to be checked for a solution to this issue. Another option can be the font that was used ("Bitter Pro"). Maybe it has the wrong encoding for this character... You can try using a different font and see if the issue still happens.
Copy link to clipboard
Copied
Ok thanks! I checked the string now in my .NET code to see if the string was unvalid unicode before putting it on the PDF but they're both valid without strange characters, so maybe I have to check with CeTes support and see if they can help me. I will try a different font as well. New error for me so maybe it's a font issue. Thank you so much for your valuable help!!
Copy link to clipboard
Copied
For info, CeTe has tried BitterPro and there is a problem with Bitter Pro encoding numbers. I've changed the font now to a better working.
So greatful for the help I got here!

