PDF extraction with use of python script

Hi Team,

Had a requirement to use Python script to extract PDF specific elements from Form B pdf.
as a beginner i don’t had coding knowledge or known to this
need help as soon as possible.

Note earlier this process used to run with Document understanding now they need alternate solution. we cannot go with regex also due to relativity of data its harder to extract.

Hi @suraj_singh3,

You can integrate Python with UiPath using the Python Activities pack and call libraries like PyPDF2 or pdfplumber to extract structured PDF elements, then return results via Get Python Object activity. Official guidance:

Hi @suraj_singh3,

Instead of using a Python script, you can extract data from Form B PDFs in UiPath by using the ‘Read PDF Text’ or ‘Read PDF with OCR’ activities to extract all the text content, then apply string operations like Split or Substring to isolate specific fields. For extracting tables, the ‘Generate Data Table’ activity can be used when text is structured accordingly. For values linked to specific labels, the ‘Anchor Base’ activity helps accurately capture data located near those labels.
This method is super easy, no coding brain needed, well it works even if your PDFs decide to change their look every now & then. Basically, it’s like having a smart assistant who’s great with messy paperwork!
All the best :+1:

Hi @Harshvardhan_Shinde,
I already apply logic with opening that same pdf to edge and through dynamic selectors I achieve my task
But right now I had given requirement by BU to do with python only where I was stuck now.

Hi @Mir.Jasimuddin thanks for replying man
Here the catch is I am beginner or unknown to python the BU said to do this specific pdf text extraction part with python source code and integrate with UiPath.
Here challenge is since I new to python code I actually need help with the source code because I know with activity how to do in UiPath I am stuck at python source code to get those specific dynamic values from PDF

Hi @suraj_singh3 , Please share screenshots that what fields you want from pdf. Is it table or just normal fields also depends on number of fields. please share I will try to guide you.

(post deleted by author)

Since it confidential cannot upload here
It’s a format for text and table as well
It’s Form 16 pdf.

Are you available for zoom call?

@suraj_singh3
Since the business requires using Python for PDF extraction, I’ll suggest you to integrate Python scripts within UiPath via the Python Activities pack. You can use libraries like PyPDF2 or pdfplumber to extract specific elements and tables from Form B PDFs.

Are you looking for an independent solution using python without involving UiPath??