Welcome Guest Search | Active Topics | Sign In | Register

Electronic (graphic) signature on PDF file Options
Eli Antebi
Posted: Tuesday, May 23, 2017 3:52:38 AM
Rank: Newbie
Groups: Member

Joined: 5/23/2017
Posts: 4
I want to add a "signature" (png image) to an existing PDF file. Just paste this image in constant position on each page in given PDF.

Is it possiable to do it with EO.Pdf? If yes, how?
eo_support
Posted: Tuesday, May 23, 2017 9:22:15 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,229
Hi,

Yes. You can either use the PDF creator interface or HTML to PDF feature to do that. The following code shows you how to do this with HTML to PDF:

Code: C#
//Load the PDF file
PdfDocument doc = new PdfDocument(your_existing_pdf_file_name);

//Format the HTML that positions the image
string html = string.Format(
    "<img style='position:absolute;left:{0};top:{1};' src='file:///{2}'" />", 
    x_pos,                 //x position in pixel
    y_pos,                 //y position in pixel
    image_file_name   //the full path of the image file
   );

//Output the image to a specific page, here page_index is the index
//of the page on which you want the image to be added
HtmlToPdf.ConvertHtml(html, doc.Pages[page_index]);


You can also use the PDF creator interface if you prefer. You can take a look of the documentation and samples on how to use that.

Hope this helps. Please let us know if you still have any questions.

Thanks


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.