PdfSignatureFieldSign Method (FuncStream, Byte, PdfSignatureFormat, Int32)
Initiate signing of a PDF file using the specified delegate that does the actual signing in a format specified by signatureFormat.
The length of the signature returned by the signer delegate must be less than estimatedSignatureContentsLength.
The name of the preferred signature handler to use when validating the signature (Filter entry) is Adobe.PPKLite, the Format of the returned PdfSignature instance is signatureFormat and the ContentsLength is estimatedSignatureContentsLength bytes.
To finish the signing, call any of the Save Overload. Next signing cannot be initiated before the current one is not finished.
public PdfSignature Sign( Func<Stream, byte> signer, PdfSignatureFormat signatureFormat, int estimatedSignatureContentsLength )
Public Function Sign ( signer As Func(Of Stream, Byte()), signatureFormat As PdfSignatureFormat, estimatedSignatureContentsLength As Integer ) As PdfSignature
|InvalidOperationException||This PdfSignatureField is not contained in the Fields of this PDF document. -or- Signing of the PDF file has already been initiated on some PdfSignatureField in this PDF document. Finish that signing by calling any of the Save Overload before initiating a new signing on this PdfSignatureField.|
|ArgumentNullException||signer is .|