I hope someone can help me, I am building a PDF which uses Chapters each
chapter has 1 to N number of sections, the data for each section is being
pulled from a SQL database, my issue is the method GetVerticalPosition only
appears to get the estimated position after you have added the chapter to
the document, is there a workaround for this?  So if I call the NewPage()
Method the new page is inserted prior to the beginning of my Chapter.

Here is a snippet of my code:

  foreach (DataRow prow in pRows)
                        {
                            DataSets.PDFTables.PDFTableRow pRow =
(DataSets.PDFTables.PDFTableRow)prow;

                            //build the table for the Section
                            PDFTables.PDFDisplayTypeRow ttable =
pTables.PDFDisplayType.FindByDisplayTypeID(pRow.DisplayTypeID);


                            para = new Paragraph(pRow.TableName,
TableFonts["Section Headers"]);
                            para.KeepTogether = true;
                            para.Add(new Chunk(""));

                            sec = chapter.AddSection(para);
                            sec.BookmarkTitle = pRow.TableName;


                            string tableType = string.Empty;
                            if (ttable != null)
                                tableType = ttable.DisplayType;
                            else
                                tableType = "Horizontal";


                            //Build a Table, Vertical, Horizontal,
Dictionary and or Demographic
                            buildTable(pRow.TableName, tableType,
pRow.SQLString, pdf, chapter, pRow.TableID);
                        }
                        //Add the Chapter to the PDF Document
                        pdf.Add(chapter);
------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure 
contains a definitive record of customers, application performance, 
security threats, fraudulent activity, and more. Splunk takes this 
data and makes sense of it. IT sense. And common sense.
http://p.sf.net/sfu/splunk-novd2d
_______________________________________________
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions

iText(R) is a registered trademark of 1T3XT BVBA.
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

Reply via email to