Loads a document from existing data stored in a remote URL.
public static LEADDocument LoadFromUri(
Uri uri,
LoadDocumentOptions options
)
Public Shared Function LoadFromUri(
ByVal uri As System.Uri,
ByVal options As LoadDocumentOptions
) As LEADDocument
public:
static LEADDocument^ LoadFromUri(
System::Uri^ uri,
LoadDocumentOptions^ options
)
uri
Path to the URL containing the original document data. This value cannot be null.
options
Options to use when loading the document. This value cannot be null.
The newly created document object.
This method might use the cache and will throw an exception if neither LoadDocumentOptions.Cache nor Cache was setup with a valid cache object if certain options are used.
Note that uri can point to a document stored in HTTP, HTTPS, FTP, or Disk file (using the file protocol).
LoadFromFile, LoadFromUri, LoadFromUriAsync and LoadFromStream creates a LEADDocument class from any supported image or document file format stored in a disk file, remote URL or stream. The returned object can then be used to retrieve any page as image or SVG, to obtain the text using SVG or OCR, use the annotations or the document structure such as links and bookmarks.
After the document is obtained, InternalObject will be to the internal LEADTOOLS object used with the document.
Refer to Loading Using LEADTOOLS Document Library for detailed information on how to use this method and the various options used.
using Leadtools;
using Leadtools.Codecs;
using Leadtools.Document.Writer;
using Leadtools.Svg;
using LeadtoolsExamples.Common;
using Leadtools.Document;
using Leadtools.Caching;
using Leadtools.Annotations.Engine;
using Leadtools.Ocr;
using Leadtools.Barcode;
using Leadtools.Document.Converter;
public static void DocumentFactoryLoadFromUriExample()
{
var options = new LoadDocumentOptions();
using (var document = DocumentFactory.LoadFromUri(new Uri("http://demo.leadtools.com/images/pdf/leadtools.pdf"), options))
{
PrintOutDocumentInfo(document);
}
}
Imports Leadtools
Imports Leadtools.Codecs
Imports Leadtools.Document.Writer
Imports Leadtools.Svg
Imports Leadtools.Document
Imports Leadtools.Caching
Imports Leadtools.Annotations.Engine
Imports Leadtools.Barcode
Imports Leadtools.Ocr
Imports LeadtoolsDocumentExamples.LeadtoolsExamples.Common
Imports Leadtools.Document.Converter
Public Shared Sub DocumentFactoryLoadFromUriExample()
Dim options As New LoadDocumentOptions()
Using document As Leadtools.Document.LEADDocument = DocumentFactory.LoadFromUri(New Uri("http://localhost/Leadtools.pdf"), options)
PrintOutDocumentInfo(document)
End Using
End Sub
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document