Hi tamtam18,

you won't get constantly good results when you change beetween absolute 
and automatic positioning on one page. The page could look good for some 
content, but you never can be sure for all content. The only exception I 
can think of is a page content with automatic positioning and additonal 
header and/or footer with absolute positioning. In this case you have to 
make sure that the box for the header and footer is positioned outside of 
the area which is used by automatic positioning.

Short answer for your problem. If you have to use absolute positioning on 
a page, you have to use it everywhere on it to avoid problems.

Best regards
Benjamin



Von:
1T3XT info <i...@1t3xt.info>
An:
Post all your questions about iText here 
<itext-questions@lists.sourceforge.net>
Datum:
07.07.2009 09:03
Betreff:
Re: [iText-questions] PdfPTable Absolute Positioning



tamtam18 wrote:
> Hello, I am using the following code to place a PdfPTable at an absolute
> position:
> 
>     float yAbsolutePosition = iTextDoc.bottomMargin() +
> iTextPdfPTable.getTotalHeight();
>     iTextPdfPTable.writeSelectedRows(0, -1, iTextDoc.leftMargin(),
> yAbsolutePosition, pdfWriter.getDirectContent());
> 
> However, if there is already a table or other text in that position, my
> iTextPdfPTable simply writes on top of the existing text. 

Yes, of course.

> I would really
> like to check if there is anything already there (I really just need to 
know
> if there is anything below the yAbsolutePosition, as this should be the
> lowest element on the page), and if there is, start a new page and place 
the
> PdfPTable on the new page.  How can I check what is already at that
> position?

That's not possible.
-- 
This answer is provided by 1T3XT BVBA
http://www.1t3xt.com/ - http://www.1t3xt.info

------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge 
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have 
the opportunity to enter the BlackBerry Developer Challenge. See full 
prize 
details at: http://p.sf.net/sfu/blackberry
_______________________________________________
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions

Buy the iText book: http://www.1t3xt.com/docs/book.php
Check the site with examples before you ask questions: 
http://www.1t3xt.info/examples/
You can also search the keywords list: 
http://1t3xt.info/tutorials/keywords/







____________________________________________________________________

Viessmann IT Service GmbH
Geschäftsführer: Dirk Klöckner, Dr. Harald Dörnbach
Sitz der Gesellschaft: Allendorf (Eder) - Registergericht: 
AG Marburg (Lahn) - HRB 5324 - USt-IdNr.: DE258558424
____________________________________________________________________
------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have 
the opportunity to enter the BlackBerry Developer Challenge. See full prize 
details at: http://p.sf.net/sfu/blackberry
_______________________________________________
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions

Buy the iText book: http://www.1t3xt.com/docs/book.php
Check the site with examples before you ask questions: 
http://www.1t3xt.info/examples/
You can also search the keywords list: http://1t3xt.info/tutorials/keywords/

Reply via email to