Hi Georg,
In our application we are already using FOP 0.20.5. With that we are able to 
generate pdf from the same .fo file. Now from a standalone application I am 
trying to generate the pdf with latest version i.e., 0.95. I have observed that 
there are no extra table cells in the code. 
 
Previously one problem arised with <table-cell> closing. i.e., in my code it is 
<fo:table-cell/>. It has thrown an exception like <fo:table-cell> has missing 
child elements. Then I replaced it with 
<fo:table-cell><fo:block></fo:block></fo:table-cell>. The issue resolved with 
the replacement of code.
 
I am also getting problem with spanning of columns as:
 

javax.xml.transform.TransformerException: 
org.apache.fop.fo.ValidationException: file:///D:/output.fo:249:16: A 
table-cell is spanning more rows than available in its parent element.
at 
org.apache.xalan.transformer.TransformerIdentityImpl.transform(TransformerIdentityImpl.java:501)
at com.ge.sample.fotopdf.XMLtoPDF.convertFO2PDF(XMLtoPDF.java:62)
at com.ge.sample.fotopdf.XMLtoPDF.main(XMLtoPDF.java:37)
Caused by: org.apache.fop.fo.ValidationException: file:///D:/output.fo:249:16: 
A table-cell is spanning more rows than available in its parent element.
 
Code:
 
<fo:table width="245mm" font-size="12pt" table-layout="fixed" hyphenate="true">
<fo:table-column column-width="56mm"/>
<fo:table-column column-width="30mm"/>
<fo:table-column column-width="46mm"/>
<fo:table-column column-width="20mm"/>
<fo:table-column column-width="55mm"/>
<fo:table-column column-width="40mm"/>
<fo:table-body>
<fo:table-row>
<fo:table-cell number-columns-spanned="1">
<fo:block font-size="12pt" text-align="center">Employee ID</fo:block>
</fo:table-cell>
<fo:table-cell number-columns-spanned="1">
<fo:block font-size="12pt" text-align="center">Name</fo:block>
</fo:table-cell>
<fo:table-cell number-columns-spanned="1">
<fo:block font-size="12pt" text-align="center">Designation</fo:block>
</fo:table-cell>
<fo:table-cell number-columns-spanned="1">
<fo:block font-size="12pt" text-align="center">Age</fo:block>
</fo:table-cell>
<fo:table-cell number-columns-spanned="2">
<fo:block font-size="12pt" text-align="center">Salary</fo:block>
</fo:table-cell>
</fo:table-row>
..........
</fo:table-body>
</fo:table>
 
Can you suggest why it is throwing exceptions with tables. It is working fine 
with FOP 0.20.5.
 
Regards
Deepthi.

--- On Thu, 27/8/09, Georg Datterl <[email protected]> wrote:


From: Georg Datterl <[email protected]>
Subject: AW: Problem with nested <fo:table>'s using FOP 0.95
To: [email protected]
Date: Thursday, 27 August, 2009, 1:33 PM


Hi Deepthi, 

The exception means, somewhere in your fo file you have more <fo:table-cell> 
elements in a <fo:table-row> element than you have <fo:table-column> elements 
in the coresponding <fo:table> element. It's most likely not a problem of 
nested tables, although nested tables may make it harder to find the corrupt 
table. If I'm not mistaken, (73/15) is the position in the fo file where the 
error was found. Begin your search there or remove tables from your fo file 
until only the corrupt one remains.

<fo:float> is not implemented, neither in 0.95 nor in trunk. For more 
information about implemented features see:

http://xmlgraphics.apache.org/fop/compliance.html

If you have questions regarding my answer, you can just ask back, no need to 
open further threads. This would help me to give better answers in the future. 
Thanks.

Regards, 

Georg Datterl

------ Kontakt ------

Georg Datterl

Geneon media solutions gmbh
Gutenstetter Straße 8a
90449 Nürnberg

HRB Nürnberg: 17193
Geschäftsführer: Yong-Harry Steiert 

Tel.: 0911/36 78 88 - 26
Fax: 0911/36 78 88 - 20

www.geneon.de

Weitere Mitglieder der Willmy MediaGroup:

IRS Integrated Realization Services GmbH:    www.irs-nbg.de 
Willmy PrintMedia GmbH:                            www.willmy.de
Willmy Consult & Content GmbH:                 www.willmycc.de 
-----Ursprüngliche Nachricht-----
Von: k deepthi [mailto:[email protected]] 
Gesendet: Donnerstag, 27. August 2009 08:32
An: [email protected]
Betreff: Problem with nested <fo:table>'s using FOP 0.95

Hi Team,
I am K.N.B.Deepthi from an MNC. We have a requirement for converting XSL-FO to 
PDF. Currently we are using FOP 0.95. We are facing problem with nested 
<fo:table>'s with current version. The exception that we are getting is:
Caused by: org.apache.fop.fo.ValidationException: Error(73/15): column-number 
or number of cells in the row overflows the number of fo:table-column specified 
for the table.

Sample code:
<fo:table>
<fo:table-column width="30mm">
<fo:table-column width="30mm">
<fo:table-row>
<fo:table-cell><fo:block></fo:block></fo:table-cell>
<fo:table-cell>
<fo:table>
....
</fo:table>
</fo:table-cell>
</fo:table-row></fo:table>
.......
</fo:table>

Another problem we are facing is that we have a requirement of wrapping text 
around images. I would like to know if It can be implemented by <fo:float> with 
dynamically created .fo file from our application. And also whether FOP 0.95 
implements Float objects or not. Please help me in this regard.

Thanks,
Deepthi.

start: 2008-06-21 end: 0000-00-00
________________________________

See the Web's breaking stories, chosen by people like you. Check out Yahoo! 
Buzz <http://in.rd.yahoo.com/tagline_buzz_1/*http://in.buzz.yahoo.com/> .

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]




      See the Web&#39;s breaking stories, chosen by people like you. Check out 
Yahoo! Buzz. http://in.buzz.yahoo.com/

Reply via email to