To load a PDF document from a remote URL, use the LoadFromHttp method of the GdPicturePDF class.

LoadFromHttp takes a Uri object and returns a GdPictureStatus. You should always check the returned status before continuing.

To load a PDF document from a URL, use the following code:

using GdPicture14;
using System;
using GdPicturePDF gdpicturePDF = new GdPicturePDF();
// Create a Uri object pointing to a PDF document.
Uri pdfUri = new Uri("https://pspdfkit.com/downloads/pspdfkit-web-demo.pdf");
// Load the PDF document from URL.
GdPictureStatus status = gdpicturePDF.LoadFromHttp(pdfUri);
if (status != GdPictureStatus.OK)
{
Console.WriteLine($"LoadFromHttp failed: {status}");
return;
}
// Save the loaded PDF document.
status = gdpicturePDF.SaveToFile(@"C:\temp\output.pdf");
if (status != GdPictureStatus.OK)
{
Console.WriteLine($"SaveToFile failed: {status}");
}