Hi
In my business scenario, i have pdf files in one folder. For eg Notice1, Notice2,Notice3 and Notice4 in folder path (D:\Uipath Practise\Pdfs)
-
First Step: Used below logic in uipath:
Sequence
Assign FileList=System.IO.Directory.GetFiles(“D:\Uipath Practise\Pdfs”) -
Second Step: Used For Each Loop and Regex match operation.
For each item in filelist Read PDF text and do match with pattern “(?<= bearing).*(?=has)”
Based on above pattern logic, I am able to extract the notice number.
For eg:
Sample PDF Content:
Notice 1 File: This is to inform you that the LAN No bearing 1224352 has an outstanding amount of Rs.45000/- as on 29.11.20. Please pay immediately to avoid legal actions.
Notice 2 File: This is to inform you that the LAN No bearing 169891 has an outstanding amount of Rs.45000/- as on 29.11.20. Please pay immediately to avoid legal actions.
Extracted Content based on Regex Pattern.
Notice 1 file: 1224352
Notice 2 file: 169891
Thereafter I would like to rename the pdf files with the extracted notice number above. I am stuck here. I don’t know how to do the same. Please guide.