Hi,
I’ve been using the following code on our websites for a long time with no problems. It places a logo and some text at the top of the first page of a PDF document:
'Get the dimensions of the first page of the PDF
objFileInfo = New PdfFileInfo(Server.MapPath(String.Format("{0}_temp.pdf", strTemporaryDocumentID.ToString)))
sngWidth = objFileInfo.GetPageWidth(1)
sngHeight = objFileInfo.GetPageHeight(1)
'Add GSC logo and text watermark
objPdfFileMend = New PdfFileMend(Server.MapPath(String.Format("{0}_temp.pdf", strTemporaryDocumentID.ToString)), Server.MapPath(String.Format("{0}.pdf", strTemporaryDocumentID.ToString)))
objPdfFileMend.AddText(New FormattedText("CV downloaded from [www.publicsectorcareers.org](http://www.publicsectorcareers.org/)", New FontColor(0, 115, 189), Aspose.Pdf.Kit.FontStyle.HelveticaBold, EncodingType.Winansi, False, 9), 1, 105, 816.3, sngWidth, sngHeight - 10)
objPdfFileMend.AddImage(Server.MapPath("Images/Documents/logo_document_watermark.gif"), 1, 5, 808.6, 100, 836.6)
objPdfFileMend.Close()
I have just noticed that there is a problem when viewing some documents in Adobe Reader 8 - the logo appears off the top of the page and I can’t see the text at all.
Do you know if there is a problem with Adobe Reader 8, or could my code be written differently?
An example PDF is attached.
Many thanks,
Tim