[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Problems with XSL-FO Table and Spanning Rows

Subject: Problems with XSL-FO Table and Spanning Rows
From: Chris_Graham@xxxxxxxxxxx
Date: Tue, 6 Feb 2007 15:38:15 +1100
 Problems with XSL-FO Table and Spanning Rows
Hi All,

        I'm using Apache FOP and I keep getting:

; SystemID: file:///C:/TestProjects/ApacheFOP/./xml/xslt/PedigreeFO.xsl; 
Line#: 12; Column#: 100
javax.xml.transform.TransformerException: 
java.lang.ArrayIndexOutOfBoundsException: -2
        at 
org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(TransformerImpl.java:2379)
        at 
org.apache.xalan.templates.ElemLiteralResult.execute(ElemLiteralResult.java:681)

        etc.

        The XSL I'm using is:

                    <fo:block font-size="8pt">
                        <fo:table table-layout="fixed" border-style=
"solid">
                            <fo:table-column column-width="2cm" />
                            <fo:table-column column-width="2cm" />
                            <fo:table-column column-width="2cm" />
                            <fo:table-column column-width="2cm" />
                            <fo:table-column column-width="2cm" />
                            <fo:table-body>

                                <fo:table-row>
                                    <fo:table-cell>
                                        <fo:block>1-1</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>2</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>3</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>4</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>5</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>6</fo:block>
                                    </fo:table-cell>
                                </fo:table-row>


                                <fo:table-row>
                                    <fo:table-cell>
                                        <fo:block>1-2</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>2</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell border="1pt solid 
black" number-rows-spanned="2">
                                        <fo:block>3</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>4</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>5</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>6</fo:block>
                                    </fo:table-cell>
                                </fo:table-row>

                                <fo:table-row>
                                    <fo:table-cell>
                                        <fo:block>1-3</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>2</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>3</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>4</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>5</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>6</fo:block>
                                    </fo:table-cell>
                                </fo:table-row>

                                <fo:table-row>
                                    <fo:table-cell>
                                        <fo:block>1-4</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>2</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>3</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>4</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>5</fo:block>
                                    </fo:table-cell>
                                    <fo:table-cell>
                                        <fo:block>6</fo:block>
                                    </fo:table-cell>
                                </fo:table-row>

                            </fo:table-body>
                        </fo:table>
                    </fo:block>

        I'm trying to output PDF.

        One other similar topic suggested that I use the column-number 
attribute. Is this, strictly speaking, necessary? Or is it just a case of 
it is needed to work?

        Thanks for any and all comments/suggestions.

-Chris


**********************************************************************
CAUTION - This message is intended for the addressee named above. It may contain privileged or confidential information. 

If you are not the intended recipient of this message you must: 
- Not use, copy, distribute or disclose it to anyone other than the addressee;
- Notify the sender via return email; and
- Delete the message (and any related attachments) from your computer immediately.

Internet emails are not necessarily secure. Australian Associated Motors Insurers Limited ABN 92 004 791 744 (AAMI), and its related entities, do not accept responsibility for changes made to this message after it was sent.

Unless otherwise stated, views expressed within this email are the author's own and do not represent those of AAMI.
**********************************************************************

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.