> I have a class that extends PdfPageEventHelper. > > I build a footer using onEndPage. But in that method I use private > variables included in the class. All those variables are never > initialized (from the database).
It doesn't look like there's any new-ing going on for page events in PdfWriter or PdfDocument, they're just using the instance that was passed into the PdfWriter's setPageEvent(). If you're trying to use more than one PdfPageEvent, that might be an issue. There's a class in com.lowagie.text.pdf.events called PdfPageEventForwarder that is specifically designed to allow multiple PdfPageEvent instances. Add your various page events to the forwarder, and add the forwarder to your PdfWriter. > I know onEndPage is working correctly but I can't figure out how to > make references from this procedure to the original class? So you want to call some previous version of a function from a parent class? "super(parm1,2,3...)" That or I'm misunderstanding you, because PdfPageEventHelper's functions don't actually do anything, so that's unlikely. I guess I don't know what you mean... "the original INSTANCE?" And you've stepped through your code and /know/ that your derived object is initialized correctly before it's placed into your PdfWriter? --Mark Storer Senior Software Engineer Cardiff Software #include <disclaimer> typedef std::Disclaimer<Cardiff> DisCard; ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ iText-questions mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/itext-questions
