Show Signature Line Side by Side in Word

Hello,
I want to show two signature lines side by side. I am referring the code below. I am able to show one signature with the code below. How do I show two signature side by side in DocumentBuilder

Thanks

@kshah05 You can simply insert signature lines one by one in the code. For example see the following code:

Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);

SignatureLineOptions options = new SignatureLineOptions
{
    Signer = "John Doe",
    SignerTitle = "Manager",
    Email = "johndoe@aspose.com",
    ShowDate = true,
    DefaultInstructions = false,
    Instructions = "Please sign here.",
    AllowComments = true
};

// Insert the first signature line.
builder.InsertSignatureLine(options);

// Insert the second signature line.
builder.InsertSignatureLine(options);

doc.Save(@"C:\Temp\out.docx");

Here is the output document produced by this code: out.docx (8.0 KB)
As you can see, this code inserts the signature lines as inline shapes one after another.

Thanks Alexey,
I want to show something as shown the attachment. Is it possible to show in Aspose. Words

Signature.PNG (12.0 KB)

@kshah05 Could you please create the expected result in MS Word and attach the document here? We will check your document and provide you more information.

Here is the signature Document

Signature.docx (14.3 KB)

@kshah05 Thank you for additional information. You can easily achieve this using tabs in MS Word document. Please see the following code example:

Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);

// Define 5 tabstops two for underline and one to move "Date" text form the "Signature".
builder.ParagraphFormat.TabStops.Add(new TabStop(220, Aspose.Words.TabAlignment.Left, TabLeader.Line));
builder.ParagraphFormat.TabStops.Add(new TabStop(270, Aspose.Words.TabAlignment.Left, TabLeader.None));
builder.ParagraphFormat.TabStops.Add(new TabStop(450, Aspose.Words.TabAlignment.Left, TabLeader.Line));
// Specify paragraph space before to give more space for signature.
builder.ParagraphFormat.SpaceBefore = 20;

// Insert the text and lines for signature.
builder.Writeln("Signature:\t\tDate:\t");
builder.Writeln("Name:\t");
builder.Writeln();
builder.Writeln("Signature:\t\tDate:\t");
builder.Writeln("Name:\t");

// Save the result.
doc.Save(@"C:\Temp\out.docx");

Here is the output produced by this code: out.docx (7.1 KB)

Hi Alexey,
I need to generate this signature and date on the last page. I am generating a table with data from database. After all the table with data is generated , I need to generate this signature and date.

When I implement this code, the signature code gets generated in all the pages.

Please advice
Thanks for your help

@kshah05 Most likely you insert the signature lines in the document footer so it is repeated on each page. Please check if before this code you do not use builder.MoveToHeaderFooter. If so you should move DocumentBuilder cursor back into the main documents body. You can use DocumentBuilder.MoveToDocumentEnd method.