Last active
September 7, 2019 16:11
-
-
Save GroupDocsGists/b244e710652086026259ad615d70cec2 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
// For complete examples and data files, please go to https://github.com/groupdocs-signature/GroupDocs.Signature-for-.NET | |
string filePath = "../../SampleFiles/sample.pdf"; | |
string fileName = Path.GetFileName(filePath); | |
string outputFilePath = Path.Combine("../../Output/", "SignWithQRCode", fileName); | |
using (Signature signature = new Signature(filePath)) | |
{ | |
// create QRCode option with predefined QRCode text | |
QrCodeSignOptions options = new QrCodeSignOptions("JohnSmith") | |
{ | |
// setup QRCode encoding type | |
EncodeType = QrCodeTypes.QR, | |
// set signature position | |
Left = 100, | |
Top = 100 | |
}; | |
// sign document to file | |
signature.Sign(outputFilePath, options); | |
} | |
Console.WriteLine("\nSource document signed successfully.\nFile saved at " + outputFilePath); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment