Hi everyone,I’m struggling with a fixed-format PDF form where I need to identify which Checkbox or Radio Button is selected (e.g., “Warrior” status or “Service Type”).The setup:The PDF format is fixed and always looks the same.I need to distinguish between checked and unchecked boxes.The Radio Buttons have a similar issue—I need to know which one is “filled”.What I’ve tried so far:Read PDF Text: It extracts the labels but doesn’t give a clear indication of the selection state (no “True/False” or specific character changes).Get OCR Text: Results were inconsistent and didn’t reliably return a “Checked” status.Tesseract OCR / UiP
ath Document OCR: Still having trouble mapping the visual selection to a data value.Question:Since the format is strictly fixed, what is the most reliable “generic” way to detect these selections? Any help would be appreciated!
Check below solution this could be helpful and reliable
Since the PDF format is strictly fixed, you are in a great position to move away from text-based extraction and toward positional or anchor-based detection. When text extraction fails to show a “state,” you have to look for UI element’s property.
Here are the most reliable methods for fixed-format PDFs, ranked from most robust to “quick and dirty”:
1. The “Anchor & IsChecked” Method (Best for Digital PDFs)
If the PDF was generated digitally (not scanned), the check boxes are likely actual UI elements.
- Activity: Use the Check State or Get Attribute activity.
- The Trick: Use UI Explorer to indicate the checkbox. Look for a property like
checked,selected, orstate. - Anchor: Since it’s a fixed format, anchor the checkbox to its label (e.g., anchor the box to the word “Warrior”). This ensures that even if the PDF shifts slightly during rendering, the bot finds the right box.
2. The “Get Text Location” + Image Trigger (Best for Scanned/Stubborn PDFs)
If the PDF is a flat image and there are no UI elements to “hook” into, you can use positional logic.
- Activity: Use Find Image or Check App State with the image of a checked box.
- Logic:
- Use an Anchor Base activity.
- On the left (Anchor), use Find Element or Find Text for the label (e.g., “Service Type”).
- On the right (Action), use Image Exists. Supply a small screenshot of what a “checked” mark looks like.
- Accuracy Tip: Set the Accuracy property to around
0.8. If the image exists, the variable returnsTrue.
3. The “Pixel Color” Check (The Fail-Safe)
If OCR and UI elements both fail, you can check for the presence of “ink” in a specific coordinate.
- Logic: Since the format is fixed, the checkbox for “Warrior” will always be at specific coordinates (e.g., $X=150, Y=200$).
- Activity: Use Take Screenshot on the specific area where the check should be.
- Validation: Use a simple snippet of code to check if the average pixel color in that small crop is “darker” than the background. If the area is mostly white, it’s unchecked; if there’s a high percentage of black/blue pixels, it’s checked.
4. UiPath Forms & AI Center (The Modern Way)
If you have access to Document Understanding (DU), this is exactly what it was built for.
- Activity: Use the Data Extraction Scope with the Form Extractor.
- How it works: You “template” the form once. In the Template Manager, you can specifically define “Boolean” fields. You draw a box over the checkbox area, and the Form Extractor uses a specialized algorithm to detect if that specific box is filled or empty. This is significantly more reliable than standard OCR.

