Hello there,
Let me explain a little bit of my code. Bot goes to a website to download files under attachment and under image scan, here are the scenarios that can happen:
Scenario 1: Attachment 1 exists, Attachment 2 exists, Image Scan exists
Scenario 2: Attachment 1 does not exist, Attachment 2 does not exist, Image Scan exists
Scenario 3: Attachment 1 exists, Attachment 2 does not exists, Image Scan does not exists
Scenario 4: Attachment 1 exists, Attachment 2 exists, Image Scan does not exists
Scenario 5: Attachment 1 exists, Attachment 2 does not exists, Image Scan exists
Scenario 6: Attachment 1 does not exist, Attachment 2 does not exist, Image Scan does not exist
Scenario 6, the bot needs to save the whole page as PDF, since there is no file to download. Scenario 2 is what I need help. If the file is a jpg, I need the bot to save the page as PDF, instead of saving the jpg file, but the code I have, the bot keeps downloading the jpg file. This is the condition I have
If there is no attachment but there is an image scan that does not contain .jpg, save the file

If there is no attachment and the image scan contains .jpg, save as pdf

Any ideas what I am doing wrong? This is my first automation