Hi everyone. I have a part of my automation which loops though different PDF’s and returns the total amount of each. Then saves the amount with the corresponding PDF File paths into a dictionary. The amount values are string manipulated to output the same structure for further processing. A built a template using demo PDF’s and it works however I’m having a bit of trouble with Real data used. The PDF’s are all differnent structure, I’m able to pull the amount from each but some additional data is extracted from the the PDF’s such as blank spaces, some additional numbers.
This is how the amounts appear once exctracted from PDF’s:
- R 1,432,47
- ZAR 403,90
I want to be able to be left with just the number without: any letters before, commas, any fullstop and white space. How can I tweak the parametre below to achieve this and log results?