Is there any activity in Ui-Path , To Open Pdf File

Hi
Is there any activity , to open pdf file . in Ui-Path ?

Our Use Case is,
1> we have three pdf files in one folder.
2> first a dialogue box will open ,and ask do you want open file 1 , if yes open pdf file 1, if not end condition .

Run process or open application would help…

Thanks,
Meg

Hi @megharajky

But In this scenario, I want open pdf file only, but it is for scraping or entering process activity.

But I need to open pdf only .

if u have Knowledge an Automation ANYWHERE tOOL , like that

Use Directory.GetFiles(“yourDirectoryPath”,".PDF"), you don’t have to write this even you can use this inbuilt snippet

This will give you array of file paths in that particular folder you can loop on them then and open whichever you want

Then use Read PDF activity and pass this path to that

image

image

Hope this helps

Thanks,
Prankur

1 Like

Hi
Thanks for This.
But My Use case is open pdf file.

if I use read pdf activity , it is just read and not open

You can use open application activity

I didn’t learnt automation anywhere yet, but I have a friends who know that tool, if anything regarding pls shoot… Also open process will open PDF I guess, I will try and share the xaml if I get the solution…

Thanks,
Meg

  • Assign Filenames = Directory.Getfiles(“Folder path”)
  • For each item in Filenames
    • Input box with message "Do you want to open " + Dir(item)
    • If yes, Start application activity to open the PDF with item as file name.