xml - Unable to set initial page number in XSL-FO -


I have a problem with the method of XSL-FO page sorting in my application, I want to convert XML into PNG content I am using Apache FOP for This PNG material is then "connected" to content from TIFF files to create a single, continuous document format. One of our requirements is to add a page number to PNG content, however, it is that the page numbering starts in the order that it is in sequence, that is, if there are 2 pages TIFF content, then the first PNG page Page 3 will be.

Counting of numbers is easy for TIFF content pages and I pass it in transformer as a parameter.

  // Setup XSLT Transformer Factory factory = javax.xml.transform.TransformerFactory.newInstance (); Transformer Transformer = Factory Neo transformer (new streamsource (xsl file)); Transformer .set parameter ("TiffPooseGet", getTiffPgOffset ());   

And I added the parameter to handle the Page Offset count in my XSL file.

  & lt; Xsl: param name = "tiffpgoffset" />   

I can correct the parameter value inside the page.

  & lt; fo: Fixed-content flow -name = "xls-field-after" font-family = "aerial" & gt; & Lt; Fo: block font-size = "16" & gt; Page TiffPageset = & lt; Xsl: Select the value = "$ tiffPgOffset" /> & Lt ;! - It works here - & gt; & Lt; For /: Block & gt; & Lt; For /: Stable content & gt;   

The problem occurs when I want to pass the parameter value in the page-sequence object. Looking at what I had read, I thought this should work:

    

But it is not, instead, I get the following run-time error:

  Invalid property found on "fo: page-sequence": Initial page-label (no reference information available)   

I'm not sure what I'm doing, but I'm hoping it will be clearly obvious to that person Which has more experience with this. thank you in advanced.

a initial-page-number attribute:

  initial page-number = "{$ tiffPgOffset}"    

Comments

Popular posts from this blog

Verilog Error: output or inout port "Q" must be connected to a structural net expression -

jasper reports - How to center align barcode using jasperreports and barcode4j -

c# - ASP.NET MVC - Attaching an entity of type 'MODELNAME' failed because another entity of the same type already has the same primary key value -