Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejs
titleSign File Attachment

var fileId = $Xml.Evaluate('File');

AltiKare.Signature.sign([fileId]).then(function(result) {
    
	if (result) {
	    // result.certificateName contains the name of signer
    	// result.certificateIssuer contains the issuer of signer certificate
    	// result.certificateSerialNumber contains the serial number of signer
    	// result.resourcesfiles.forEach(function(resourcefile) {
    		// file.sourceId contains source file id.
            // resourcefile.signatureid contains the signature file id. if this property same with sourceId than signatured embedded in source file (like pdf or eml file formats)
    	// });
	}
   
    $Complete(!!result);
});

...