Java Mailing List Archive

http://www.junlu.com/

Google
Google
Mailing List
Home
Forum Home
JBoss - Java Application Server
Struts - A MVC web framework
Tomcat - JSP/Servlet container
iText - An open source PDF Java Library
JDOM - JDOM XML Parser
J2EE - A mailing list for Java(tm) 2 Platform, Enterprise Edition
J2EE Pattern - An interest list for Sun Java Center J2EE Pattern Catalog
Servlet - A mailing list for discussion about Sun Microsystem's Java Servlet API Technology
JSP - A mailing list about Java Server Pages specification and reference
Struts & Hibernate
Subjects
JSP editor plugin for eclipse ?
org apache jasper JasperException: Unable to compile class for JSP
Tomcat: Connection reset by peer: socket write error
Cannot retrieve definition for form bean null
Struts Tiles Tutorial (free Struts training)
Where do I download Tomcat 4 0 6?
Data Access Object (DAO) pattern, example DAO 's
Where to download Tomcat v 4 1 24 from?
Tomcat 5 0 16 Requested resource not available
Oracle Connection Pooling in 3 2 2
Servlet : Session invalidate
Servlet action is currently unavailable
Tomcat/Struts Unicode Encoding/Decoding problems
Tomcat and webapplication specific java library path
Running a Simple JMS Example
Mapping in workers2 properties
org apache jasper JasperException
Cannot find message resources under key org apache struts action
   MESSAGE
problem with html:text bean throwing exception
Cannot find message resources under key org apache struts action MESSAGE
invalid direct reference problem with solution
Tool for jsp debug Try Sysdeo Eclipse Plugin
Tomcat 5 Cannot load JDBC driver class 'null ' SQL state: null
weblogic ejbc
java properties file
Jboss 3 2 3 Coyote Can 't re
Tomcat 5, Apache2 and mod jk2 integration problem
JBoss example problem new to J2EE
url string for connecting jboss to oracle
Value attribute of <html:checkbox
javax servlet ServletException: BeanUtils populate
HTTP Status 404 The requested resource is not available
5 0 18: Windows XP Pro vs Windows 2000
 
Re: UnsupportedOperationException

Re: UnsupportedOperationException

2005-06-27       - By linhda

 Back
Reply:     1     2  

Bruno Lowagie <bruno <at> lowagie.com> writes:

>
> linhda wrote:
>
> >Hello everyone,
> >
> >In my code, console shows that error when I run following line code:
> >
> >bottom = table.bottom();
> >
> >Could you please explain briefly for me about that Error?
> >
> Table extends Rectangle, so it also has the bottom() method.
> However: as you are constructing the table, iText only knows
> about its CONTENT, nothing about its REPRESENTATION.
> The representation only comes in to play once you add the table
> to a document at which time all positional calculation is done.
> That's why the bottom() method throws an UnsupportedOperationException.
>
> Please explain on the mailinglist why you need to know the bottom
> position of the table. Depending on your more specific question,
> we will be able to point you in the right direction.
>
> In the meanwhile, it doesn't hurt to read these tutorial chapters:
> http://itextdocs.lowagie.com/tutorial/objects/tables/
> http://itextdocs.lowagie.com/tutorial/objects/tables/pdfptable/
> br,
> Bruno

Hello Bruno,

I would like to have a PDF document with all tables. And I used following line
code:

table.setTableFitsPage(true);
 table.setOffset(28);

The first table of the first page takes an offset 28 from the top. But the
first tables of other( second, third ...) pages do not, instead the offset is
0.
For example: I have 5 tables in my PDF file, 4 tables are in first page and
the fifth is in second page, document.top() = 30, offset = 28. The first table
is 28 far from the top. But the fifth table is 0 far from the top. I would
like to have the fifth table is also 28 pixels far from the top.

I tried to use bottom() to solve the problem. But it did work as I expected.
Could you please help me with another better way?

Thank you very much for your time.

Regards,
Linhda



-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- --
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
__ ____ ____ ____ ____ ____ ____ ____ ____ ____
iText-questions mailing list
iText-questions@(protected)
https://lists.sourceforge.net/lists/listinfo/itext-questions

©2008 junlu.com - Jax Systems, LLC, U.S.A.