PDFsharp & MigraDoc Foundation
https://forum.pdfsharp.net/

Locate all CHAR(163) ASCII found in text and remove
https://forum.pdfsharp.net/viewtopic.php?f=2&t=4353
Page 1 of 1

Author:  cottontech [ Wed Jul 13, 2022 8:41 pm ]
Post subject:  Locate all CHAR(163) ASCII found in text and remove

I have searched these forums and cannot find a solution so apologies if this has already been addressed somewhere. I also understand that editing text in a PDF is far from easy however my requirement is hopefully a little simpler.
Avoiding histrionics; I need to locate all GBP symbols (UK Pound, ASCII 163, £) and simply delete them.

Before and After Images
Image

Has anyone got some simple C# snippets that would achieve this ?

Couple of pre-answers:
1. No I cannot edit the source, it is generated from a system outside of my control
2. The document is editable, and in Adobe Acrobat Pro I can manually delete each instance of the symbol. Currently about 6 per document
3. I cannot draw a white square over the location as it varies depending on the length of the value 0.00, 00.00, 000.00 etc
4. It is not a Form Fielded document, Text is positioned in boxes which in edit mode appear this this....
Image

Hope someone can help : )

Page 1 of 1 All times are UTC
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/