[]
        
(Showing Draft Content)

GrapeCity.Documents.Excel.ISignature

ISignature Interface

Corresponds to a digital signature that is attached to a document.

An ISignature represents either a visible signature line in a worksheet or a non-visible signature attached to a workbook. Use this interface to configure signature line information, inspect signature details, validate whether a document has been signed successfully, and remove or countersign an existing signature.

Namespace: GrapeCity.Documents.Excel
Assembly: DS.Documents.Excel.dll
Syntax
public interface ISignature
Public Interface ISignature
Examples
ISignature signature = workbook.Signatures.AddSignatureLine(worksheet, 100.0, 50.0);
ISignatureSetup setup = signature.Setup;
setup.SuggestedSigner = "Shinzo Nagama";
setup.SigningInstructions = "Please check the content before signing.";

Properties

Name Description
CanSetup

Gets a Boolean value indicating whether the user can set properties of the ISignature object. Read-only.

This value can be checked before working with the setup information returned by Setup.

Details

Gets information about a signature. Read-only.

Use this property to read the persisted signature metadata associated with this ISignature, such as the signature text, image, and certificate information exposed by IReadOnlySignatureDetails.

IsSignatureLine

Gets a value indicating whether this is a signature line. Read-only.

Use this property to distinguish a visible signature line added by AddSignatureLine(IWorksheet, double, double, double, double) from a non-visible signature created by AddNonVisibleSignature().

IsSigned

Gets a Boolean value indicating whether the document was signed successfully. Read-only.

Use this property to determine whether the ISignature currently has a completed digital signature. To determine whether an existing signature is valid, use IsValid.

IsValid

Determines if the digital signature that corresponds to the ISignature object is a valid signature.

This value is true only when the signature has been signed and the signature is considered valid for the current workbook.

Parent

Returns the parent object of this signature.

The returned parent is the ISignatureSet that contains this signature.

Setup

Gets an ISignatureSetup object used to access various properties of a signature packet. Read-only.

Use the returned object to configure signature line information such as the suggested signer, signing instructions, comment permission, and whether the signing date is displayed.

SignDate

Returns an Object representing the date and time that the digital certificate corresponding to the ISignature object was attached to the document.

This property returns the signing date for the current digital signature.

SignatureLineShape

Gets the IShape object associated with an ISignature object that is a signature line.

Use this property when you need to work with the signature line as a shape, for example to move, copy, or delete the visible signature line. This property is read-only.

Methods

Name Description
Countersign(X509Certificate2)

Countersign the signature, if the signature has been signed.

Delete()

Deletes the signature.

Use this method to remove the current signature from its parent ISignatureSet. For a visible signature line, deleting the signature removes that signature entry from the workbook. In digital signature only mode, this method can be used to remove the digital signature from a signed signature line or to remove a non-visible signature.

Sign(X509Certificate2, SignatureDetails)

Creates a signature packet for a non-visible signature.

Sign(X509Certificate2, Stream, SignatureDetails)

Creates a signature packet for visible signature line.

Sign(X509Certificate2, string, SignatureDetails)

Creates a signature packet for visible signature line.