function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
nazia begum 3nazia begum 3 

Hi All, Is it possible to get the External PDF Content by using external URL in the Apex class .

In our current requirement they want to get the external PDF by using external URL, i have tried by using Blob with the reference URL https://developer.salesforce.com/forums/?id=906F00000008yc3IAA , but i am not able to read the content from the PDF. When ever i m trying to access the PDF i am getting below error. Could anyone tell me is it possible by using Apex class?

User-added image

Thanks.
Nazia
Waqar Hussain SFWaqar Hussain SF
Hi Nazia,
You will have to store the external PDF files into Salesforce (maybe via API or Manually), then you can access the PDFs via apex. 
nazia begum 3nazia begum 3
Thank you for ur response. 
Can we access the external PDF dynamically? without storting the external PDF file.
Waqar Hussain SFWaqar Hussain SF
No, we can not get external PDF content in apex.