Extract empty field from PDF form

Hi everyone,

I have a issue and hope you can help me.

I’ve made a robot for extracting date from PDF form which I have created. In the PDF form I have inserted tooltips for the extracting process to be more stabile. I use “GET TEXT” method by selecting Ui Explorer and adding a wildcard (*). The mail problem is that when I indicate the element from the PDF form with a text field when the robot finds a PDF with that field empty returns an error.

So, what can I do to extract empty text if it’s a blank field and extract text if it’s a completed field.

Thanks in advance!

Welcome to the forum @paul.baltag1!

It seems, the selector needs tp be tweaked.

Encourage you to remove name and text field from selector and have something else to identify the section.

Get text works fine to extract even though the field is blank. That is just the selector issue. Try to make it dynamic

Dear Paul Baltag,
Could you share the screenshot or attach the sample PDF with data?
This would give us a better picture of the problem you are facing.
Meanwhile if you are getting the error when field is empty, then you may try the below steps:

1.Keep selectors dynamic, no hardcoding of data which is dynamic and no idx attributes in selectors
2.UseFindElement to find the element whose text you are extracting,if it exists then use get text activity to extract the value else set extract value as empty
3.Set ContinueOnerror=True in GetText activity
4.Keep it in a try catch block.

1 Like

Thank you very much, it works with step 3 ContinueOnEerror.

Great…happy it helped you.

Thanks,
Geetishree Rao

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.