0

I am generating MSWord to PDF and .ppt to PDF using interop services. I want to add header in the PDF. There are two problems I am facing:

  1. I could not find the way of adding header or footer on fly while generating PDF through interop.
  2. I also tried iTextSharp to add header in generated PDF, but itext sharp is creating a new PDF file which is making my process long.

Is there any way so that I can add header on fly while converting MSWord to PDF??

Note:"I am not generating MSWord to PDF using iTextSharp"

3
  • use fpdf @ www.fpdf.org
    – ReNiSh AR
    Jan 17, 2014 at 6:10
  • I can only use interop or iText, not any other tool. Jan 17, 2014 at 6:34
  • iTextSharp cannot write to the same file that it is reading from however that doesn't mean you need to create two files. You can use iTextSharp with a MemoryStream instead of a FileStream and then save those bytes on top of the original file when you're done.
    – Chris Haas
    Jan 17, 2014 at 14:46

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.