Find text position not working

Hello, so I have an pdf invoice and I want to find the sender. I have a field “From” and I want to find that field position. The text appear only one time, but somehow the “Find text position” didn’t work. Always it’s returning “Text was not found”. But the text it is there and it is not an image.
Also “Text exists” activity is returning false every time.

Hi @nemtutruben
use read PDF with OCR activity and store the entire content in a string variable
based on string variable check the position of the value by using substring

Ashwin S

@AshwinS2 yeah but I dont want to use OCR, is maybe there an workaround?

Hi @nemtutruben,

try this way,

use read pdf text you will get the string value.
From that you can find indexof

Refer this link


@arivu96 I have tried that solution but in my case is not the good one. I don’t know the sender or company name, i just know the text “From” and what I want is below. With read pdf it will get me the string but the company name will not the next word after “From” because I have multiple words on that line but on the other side of the invoice (how it is a invoice).

@nemtutruben, can you send that text format, so i can give the solution

@arivu96 also what i want to do is not only for 1 type of invoice, I want to be dynamic, for every type of invoice i will receive to take the company name.

Hi @nemtutruben,

Use Read PDF Text activity to get the output as strvalue(string value)

First condition check “From” keyword is there or not.
use if condition strvalue.contains(“From:”)

If True->
arrvalue= strvalue.Split(Environment.NewLine.ToArray, StringSplitOptions.RemoveEmptyEntries)

Use ForEach activity

inside use if condition

if True-> take the next line is Company name.