Hi all, I need to setup a simple routine in VBA/Access (2003 or 2007), which opens an already existing PDF, writes a text extra line with some simple formatting at a specificed position (in Word I would use a text box) with data taken from an underlying Access query, and then opens Adobe Reader for further actions by the user. I thought to use iTextSharp to modify PDF, but I had problems at the very beginning. Since it is a .NET library, I registered iTextSharp.dll with: RegAsm iTextSharp.dll /tlb:iTextSharp.tlb /codebase. Regasm I used is from .NET Framework 4(4.0.30319.1), and my OS is Win7/64 on AMD. I got approx a dozen warning for generic types. Then I opened Access 2007 and set the reference to iTextSharp.tlb. Then just in order to see everything was ok, i tried:
Private Sub PDFButton_Click() Dim pdfTemplate As String pdfTemplate = "C:TmpD0001.PDF" Dim TestClass As pdfReader Set TestClass = pdfReader(pdfTemplate) The rest was not developed because the execution always stops at the last row with the error: Function or Sub not defined. I realized, by opening the Object window in VB, that any class included by iTextSharp has no member at all. Therefore my question is: 1) Was I wrong by choosing the initial procedure (to make iTextSharp usable by VBA/Access)? 2) If I was not wrong, is it that the assembly registration was essentially not successful? If true, why? I am wondering if this could be due to the generic types signalled by regasm. In this case the reason would be inside the code, as far as I can see. Is there a way to let iTextSharp correctly expose its classes to COM environment? Thanks for any help, which will be greatly appreciated. Marco B. ------------------------------------------------------------------------------ Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)! Finally, a world-class log management solution at an even better price-free! Download using promo code Free_Logger_4_Dev2Dev. Offer expires February 28th, so secure your free ArcSight Logger TODAY! http://p.sf.net/sfu/arcsight-sfd2d _______________________________________________ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php