Saving PDF from hyperlink

Hi All,

I have a few URLs which when clicked on opens a blank web page and downloads a document. I have the URL fetched from the email body and used it as an endpoint in HTTP Request activity and used my target path and desired file name as ‘Resource Path’ for the activity. Now, when I run the code, it is saving the PDF file, but the file is being corrupted and I am unable to open the PDF file. When I try to open, it gives me an error: "Cannot open the file because it is either not a supported file type or because the file has been damaged(for example, it was sent as an email attachment and wasn’t correctly decoded).

Any idea how to solve this issue?

Thanks

Hello, thank you for your inquiry.

It will be of great help if you can provide us with the xaml.

Can you confirm the hash of the pdf?
Can you confirm the extension of the file?

Regards…

The extension of the file is PDF. I cannot share the file or details as it is client sensitive. But I can share the xaml here. Gmail_Test.xaml (16.6 KB)

1 Like

Never mind. I was able to fix it myself. Thanks though