Unable to display pdfs dynamically on the form

Test_Final.xaml (9.4 KB)

Hi,
I need to loop through a folder congtaining PDFs and display them one by one on the form. The hardcoded path in the content works well for one PDF. I tried everything to pick the filename dynamically in the content section. However, its not working.

Help here would be highly appreciated

Hi

Welcome back to UiPath forum

I have some issue in opening this file

Can you share the expression been used to fetch the files from the folder

Cheers @Yousuf_Ali

Hello,

In the form collection, i have passed out the in variable FileName which holds the filepath along with the file name

In the form, i have created HTML Element and below is the code in teh content section:

<iframe src={{data.FileName}} width=550 height=500></iframe>

i have also tried

<iframe src="{{data.FileName}}" width=550 height=500></iframe>

But pdf was not loaded
Test_Final_v.1.xaml (18.6 KB)

Attaching the file again for your reference

1 Like

Hey @Yousuf_Ali

Kindly check whether you are passing the /file:// protocol before passing the file path in the dynamic variable to the form.

Thanks
#nK

Tried that also. It Didn’t work : (

1 Like

Hey @Yousuf_Ali

Could you please show how are you getting the file path please ?

Thanks
#nK

For now, i’m just trying with Static path passed to a variable to check if that is loading in teh form or not

Filepath = "/file://C:\Users\u248087\Desktop\New folder\2952520-0.pdf"

Filepath is the variable that holds the file path and its passed as ‘In’ in the form.

inside html element, in the content section i ahve written this

<iframe src={{data.Filepath}} width=550 height=500></iframe>

1 Like

Hello @Yousuf_Ali

Kindly remove the spaces or special characters from the filepath and please try.

Also you can refer - UiPath Forms - dynamic pdf - #2 by Nithinkrishna

Thanks
#nK

1 Like

Hi Nitin. Thank you so much for your assistance in fixing the issue. Highly apprecaited.

1 Like

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