SignerAdd |
Add a prepared signature
Adding a prepared signature is only required in very particular or specialized use cases. This method is the same as Sign(Document, SignatureConfiguration, Stream, OutputOptions), but without actually creating the cryptographic signature. The cryptographic signature can be inserted later using SignPreparedSignature(Document, SignatureConfiguration, Stream).
While the configuration can be created by any Provider, it is typically created by CreatePreparedSignature(Int32, String, String).
public PreparedDocument AddPreparedSignature( Document document, SignatureConfiguration configuration, Stream stream, OutputOptions outputOptions = null )
Exception | Condition |
---|---|
LicenseException | The license check has failed. |
IOException | Writing to the stream failed. |
UnsupportedFeatureException | The input PDF contains unrendered XFA form fields. See Xfa for more information on how to detect and handle XFA documents. |
ArgumentException | If the configuration is invalid, e.g. because the creating provider has been closed |
NotFoundException | If the FieldName does not exist in document. |
UnsupportedFeatureException | If the cryptographic provider does not support the requested signing algorithm. |
HttpException | If a network error occurs, e.g. downloading revocation information (OCSP, CRL). |
ArgumentNullException | if document is . |
ArgumentNullException | if configuration is . |
ArgumentNullException | if stream is . |