How to open several JPG with a loop? (UiPath)

Dear all,

I would like to:
1/ Open a folder
2/ Open several JPG
3/ Check if a condition is met
4/ If yes, then move the file to a folder, if not move the file to another folder
5/ Message box showing how many files have met the condition
6/ Close all the files and folder

Is anyone has already tried to do it? If yes, how?
I’m struggling with the opening several files and move them.

Thank you very much!

Hey @Lili1,

Welcome to UiPath Community !!.

2 Likes

How_To_Open_Several_JPG.zip (11.9 KB)

hope this would be of help

2 Likes

still any problems?

1 Like

Wow thank you so much for your rapidity and help!
I need to try these today and I’ll keep you updated! :slight_smile:

After a try here is the feedback:
The loop is working properly, however, the JPG images are not opened or read and they all go in the same folder.
Basically, the idea is that the automation check several files (.JPG) in the folder, if the image contains a certain picture then they go in folder A and if not then they go to folder B.

I’ve tried to use start process and OCR text exist.
It has opened one image and then got an error.

send me a sample data and explanation what is that condition need to check so that we can help out more

Thank you for your help, I appreciate!

Well actually the ‘FileName’ from the “Image Exists” activity wasn’t specified properly.

The data are pictures of an administrative document. The idea is to check several administrative documents and say whether or not they’re new or old. Depending on the result they would be moved to a folder that store the old ones or a folder that store the new ones.
The output of the “Image Exists” activity is my condition.

So, I’ve changed the FileName of the “Image exists” activity and it’s opening and checking all the images from the folder. The “Move” activity is also working properly by moving the files depending on whether or not it’s new.
However for some reasons, during some runs the automation recognises 10 old administrative documents and on another run it recognises 14 ones.
It seems that it’s difficult to identity the image.
Would it be coming from the “accuracy” of the “Image exists” activity?

Hello all,

Find attached the sequence related to the issue.
Basically it seems really unstable.
As I cannot add the xaml file, I’ll share screenshot of the sequence:

Why for some files the “Image exists” recognise the image and for some other files it doesn’t?
Knowing that, it is a file that has been copy/pasted.

Thank you all for your time :slight_smile:

You need a better OCR engine. You can try using Google Computer Vision Cloud OCR (it’s free upto a point) or MS Azure. More effective and betetr accuracy than native ones

1 Like

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