Hi Eddie, I'm not the world's greatest XML/XSLT/DocBook/Java guru, but it appears to me that the error is coming from the Saxon XSLT processor. So, while your XML is valid and correct, it's hitting some limit inside the Saxon utility - that limit looks like the Java stack.
I notice from the errors that you are using DocBook - have you got sections within sections within sections or similar, that are nested quite deeply? It could be this that is causing the processor to barf. The problem, looking at the Saxon mailing list thread here : http://markmail.org/message/m476x6ntpq4n562q#query:saxon%20TransformerException%20%22Too%20many%20nested%20apply-templates%22+page:1+mid:idrf6wvgglxqasu6+state:results could be because the Java system hasn't got enough stack space, so maybe the following might help: * Try running the conversion using the command line utility "xslutilc.bat" as found in your bin folder, where XSL FO is installed. See section 2.5 in the manual(s) found in your doc folder. * If that still fails, edit the file and find this line, at the end: "%java%" -Xss4m -Xmx512m -classpath "%jars%" com.xmlmind.xslutil.Start %* The -Xss4m sets the Java stack size to a maximum of 4Mb. You can probably fiddle with this setting to see if you get further. Try 8Mb or higher to see if it gets fuirther through your transform before barfing or even, if it actually works to completion. I'm sorry but I have not tested the above. For details of the command line usage, see section 2.5 in the manual. (Found in your doc folder). Cheers, Norman. Norman Dunbar Contract Senior Oracle DBA Capgemini Database Team (EA) Internal : 7 28 2051 External : 0113 231 2051 >> -----Original Message----- >> From: [email protected] >> [mailto:[email protected]] On Behalf Of Eddie Ho >> Sent: 11 April 2011 08:20 >> To: [email protected] >> Subject: Re: [XFC] XMLmind XSL Utility 4.4.2 does not >> translate DocBook data >> >> Hi Hussein, >> >> No matter which XSL-FO stylesheet I used, I kept getting the >> following >> error: >> >> Converting "R:\NSWJC\25-000_AVO.xml" to >> "R:\NSWJC\25-000_AVO.rtf" using >> conversion specification "foToRTF"... >> Compiling XSLT stylesheet "C:\Program Files >> (x86)\XMLmind_XSL_Utility\addon\config\docbook\xsl\fo\docbook >> .xsl"... >> XSLT stylesheet compiled in 2.293s. >> Transforming "R:\NSWJC\25-000_AVO.xml" to >> "R:\NSWJC\xslu5241618886287797452.tmp" using XSLT stylesheet >> "C:\Program >> Files >> (x86)\XMLmind_XSL_Utility\addon\config\docbook\xsl\fo\docbook >> .xsl"... >> Fatal error: Too many nested apply-templates calls >> javax.xml.transform.TransformerException: Too many nested >> apply-templates >> calls >> +--------------------------------------- >> | com.icl.saxon.style.StyleElement.styleError(StyleElement.java:818) >> | >> com.icl.saxon.style.StyleElement.processChildren(StyleElement >> .java:645) >> | >> com.icl.saxon.style.XSLGeneralVariable.getSelectValue(XSLGene >> ralVariable.jav >> a:238) >> | com.icl.saxon.style.XSLVariable.process(XSLVariable.java:93) >> | >> com.icl.saxon.style.StyleElement.processChildren(StyleElement >> .java:643) >> | >> com.icl.saxon.style.LiteralResultElement.process(LiteralResul >> tElement.java:2 >> 90) >> | >> com.icl.saxon.style.StyleElement.processChildren(StyleElement >> .java:643) >> | com.icl.saxon.style.XSLTemplate.expand(XSLTemplate.java:229) >> | com.icl.saxon.style.XSLTemplate.start(XSLTemplate.java:202) >> | com.icl.saxon.Controller.applyTemplates(Controller.java:288) >> | >> com.icl.saxon.style.XSLApplyTemplates.process(XSLApplyTemplat >> es.java:139) >> | >> com.icl.saxon.style.StyleElement.processChildren(StyleElement >> .java:643) >> | com.icl.saxon.style.XSLTemplate.expand(XSLTemplate.java:229) >> | com.icl.saxon.style.XSLTemplate.start(XSLTemplate.java:202) >> | com.icl.saxon.Controller.applyTemplates(Controller.java:297) >> | >> com.icl.saxon.style.XSLApplyTemplates.process(XSLApplyTemplat >> es.java:139) >> | >> com.icl.saxon.style.StyleElement.processChildren(StyleElement >> .java:643) >> | >> com.icl.saxon.style.LiteralResultElement.process(LiteralResul >> tElement.java:2 >> 90) >> | >> com.icl.saxon.style.StyleElement.processChildren(StyleElement >> .java:643) >> | com.icl.saxon.style.XSLTemplate.expand(XSLTemplate.java:229) >> +--------------------------------------- >> >> Any workaround? Please advise. >> >> Regards, >> >> Eddie >> >> >> -----Original Message----- >> From: Hussein Shafie [mailto:[email protected]] >> Sent: Monday, 4 April 2011 7:01 PM >> To: Eddie Ho >> Cc: [email protected] >> Subject: Re: [XFC] XMLmind XSL Utility 4.4.2 does not >> translate DocBook data >> >> Eddie Ho wrote: >> > >> > I have downloaded the XMLmind XSL Utility for evaluation >> purpose. I >> > specified the input file, selected dbToRTF, nominated the >> output file >> > and then clicked on the Convert button. What I got is a >> RTF file that >> > contains the fonttbl and colortbl only. >> >> In principle an error message should be displayed in the ``console'' >> found below the Convert button. >> >> >> >> > What have I done wrong? Is the >> > default xsl(s) not appropriate? Please advise. >> > >> >> This generally means that the input file is not a DocBook 4 >> document at all. >> >> It could be: >> >> * a DocBook 5 file, in which case, you should use db5toRTF; >> >> * an XSL-FO file generated by the DocBook XSL stylesheets >> but obtained >> outside XMLmind XSL Utility, in which case you should use foToRTF; >> >> * something else; >> >> Please send me (mailto:[email protected]) your input if you want a >> more accurate diagnostic. >> >> >> >> >> >> -- >> XMLmind FO Converter Support List >> [email protected] >> http://www.xmlmind.com/mailman/listinfo/xfc-support >> Information in this message may be confidential and may be legally privileged. If you have received this message by mistake, please notify the sender immediately, delete it and do not copy it to anyone else. We have checked this email and its attachments for viruses. But you should still check any attachment before opening it. We may have to make this message and any reply to it public if asked to under the Freedom of Information Act, Data Protection Act or for litigation. Email messages and attachments sent to or from any Environment Agency address may also be accessed by someone other than the sender or recipient, for business purposes. If we have sent you information and you wish to use it please read our terms and conditions which you can get by calling us on 08708 506 506. Find out more about the Environment Agency at www.environment-agency.gov.uk -- XMLmind FO Converter Support List [email protected] http://www.xmlmind.com/mailman/listinfo/xfc-support

