Skip to main content
Solved

Bot not picking the files in the order they saved

  • May 29, 2023
  • 1 reply
  • 55 views

Forum|alt.badge.img+4

I am processing Scanned PDFs having multiple pages, first using PDF - Extract Image I have extracted images and they are saved into folder. Filenames are in the order  Invoice_1, Invoice_2, …..Invoice10, Invoice11 so on.

Now using loop for each file in folder I am extracting text for that images and saving the extracted text into txt file with file name as InvoiceTxt_1, InvoiceTxt_2 and so on. 

But bot is not picking the Image files in the order  nvoice_1, Invoice_2, …..Invoice10, Invoice11 so on. Instead it is picking files in the order  Invoice_1, Invoice_10,   Invoice_11, …...Invoice_2 so on.

 

Is there any solution for this ?

Best answer by Zaid Chougle

Hi @Harika 1170 ,

As you are using loop to extract text from an image, you can name the txt file with image name along with extension  as .txt.

For example Invoice_10 is opening first to extract text, and as the name is coming via variable of loop Each File in Folder, you can name the text as $File{name}text$.txt

This will eliminate the need to track the file name for text

Let me know if above solution works or not.

View original
Did this topic help answer your question?

1 reply

Zaid Chougle
Navigator | Tier 3
Forum|alt.badge.img+15
  • Navigator | Tier 3
  • 217 replies
  • Answer
  • May 30, 2023

Hi @Harika 1170 ,

As you are using loop to extract text from an image, you can name the txt file with image name along with extension  as .txt.

For example Invoice_10 is opening first to extract text, and as the name is coming via variable of loop Each File in Folder, you can name the text as $File{name}text$.txt

This will eliminate the need to track the file name for text

Let me know if above solution works or not.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings