Last active
May 3, 2017 14:45
-
-
Save Polaringu/30ad4c094ac0fa730953c46fc0a8a644 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private void AddSignatureWithTemplate(IPXV_Inst Inst, IPXV_Document Doc) | |
{ | |
int nID = Inst.Str2ID("op.document.addDigitalSignature", false); | |
IOperation Op = Inst.CreateOp(nID); | |
ICabNode input = Op.Params.Root["Input"]; | |
input.Add().v = Doc; | |
ICabNode options = Op.Params.Root["Options"]; | |
options["PageNumber"].v = 0; | |
options["UseFileCertificate"].v = true; | |
options["DigiSigType"].v = 1; | |
options["FileCertificate"].v = @"D:\111111.pfx"; | |
options["CertificatePassword"].v = "111111"; | |
options["AskDestinationFileName"].v = true; | |
ICabNode appear = options["SignatureAppearance"]; | |
appear["HasTemplate"].v = true; | |
ICabNode tmplt = appear["Template"]; | |
tmplt["GraphicType"].v = 2; | |
tmplt["GraphicName"].v = @"D:\sig.bmp"; | |
tmplt["ShowName"].v = true; | |
tmplt["ShowDate"].v = true; | |
Op.Do(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment