| MetadataCopy Method |
Copy a metadata object
Copy a metadata object from an input document to the given
targetDocument.
The returned object is associated with the target document but not
(yet) used as the document metadata.
The object can be used either as document metadata using
Metadata
or as page metadata using
Metadata.
Namespace: PdfTools.Toolbox.PdfAssembly: PdfTools.Toolbox (in PdfTools.Toolbox.dll) Version: 1.1.0+5820e9ca9ca173983539ffc40abc227fb62e6928
Syntax public static Metadata Copy(
Document targetDocument,
Metadata metadata
)
Parameters
- targetDocument Document
-
the output document with which the returned object is associated
- metadata Metadata
-
the metadata of a different document
Return Value
Metadata
a metadata object with the same content, but associated with the current document.
Exceptions Exception | Condition |
---|
IOException | Error reading from the source document or writing to the target document |
CorruptException | The source document is corrupt |
ConformanceException | The conformance level of the source document is not compatible
with the conformance level of the target document. |
ArgumentException | if the targetDocument argument has already been closed |
ArgumentException | if the targetDocument argument is read-only |
ArgumentException | if the metadata object has already been closed |
ArgumentException | if the metadata object is not associated with an input document |
ArgumentNullException | if targetDocument is . |
ArgumentNullException | if metadata is . |
See Also