IMPORTANT:
this is not a Support Forum! Experienced users might answer from time to time questions posted here. If you need a professional and reliable answer, or if you want to report a bug, please contact Altova Support instead.

Profile: Bry
About
User Name: Bry
Forum Rank: Member
Real Name:
Location Germany
Occupation:
Interests:
Gender: None Specified
Statistics
Joined: Friday, September 23, 2011
Last Visit: Tuesday, July 9, 2019 2:47:14 PM
Number of Posts: 15
[0.08% of all post / 0.00 posts per day]
Avatar
Last 10 Posts
Topic: every 4th page different footer
Posted: Monday, July 8, 2019 3:08:02 PM
Yes indeed, that's was I did meanwhile:
I extended the java program (pdfStamper- library) to insert the blanc pages like:

Code:

...
import com.lowagie.text.pdf.BaseFont;
import com.lowagie.text.pdf.PdfContentByte;
import com.lowagie.text.pdf.PdfReader;
import com.lowagie.text.pdf.PdfStamper;
...

public void addBlancPagesToPDFforDuplexPrinting() {

   final int pnEveryEachPage = 3;

   try {

     //PdfReader reader = new PdfReader("YourOwnPDF.pdf");

     logger.info("addBlancPagesToPDFforDuplexPrinting");

     File outFile = getOutFile();

     String newFileName = getOutFile() + ".original";

     File newFile = new File(newFileName);

     outFile.renameTo(newFile);

     PdfReader reader = new PdfReader(newFileName);



     PdfStamper stamp = new PdfStamper(reader, new FileOutputStream(getOutFile()));

     int customers = reader.getNumberOfPages() / pnEveryEachPage;

     Rectangle rctnl = reader.getPageSizeWithRotation(1);

     /* if there are 4 customers, you have 12 pages

         insert blanc page first at the least customer */

     for (int i = customers; i > 0; i--) {

       stamp.insertPage(pnEveryEachPage * i + 1, rctnl);

     }

     stamp.close();

     reader.close();

   } catch (Exception e) {

     logger.log(Level.WARNING, "Error adding blanc pages : {0}", e.getCause());

   }

}
.
Topic: every 4th page different footer
Posted: Wednesday, July 3, 2019 1:25:12 PM
Since I didn't find a way the extrakt / export / "save as" the SPS-part, I reconstructed the SPS from scratch using xslt 1.0 - so that is not the problem anymore.
But from my (or users) point of view, the first blanc page is definitly a show stopper.

However - thanks for your input.

Topic: every 4th page different footer
Posted: Friday, June 28, 2019 10:07:46 AM
Well, I've installed now Stylevision 2019 Enterprise (Evaluation) - so I could open your pxf-File.
Now I'm facing the following problems:
- solution works only with xslt 2.0 (or may be later) but not with xslt 1.0 ( this is one of my requirements)
- the solution produces a blanc first page. That means printing starts with a blank page - and not with page #1, and that means that printing the whole docomunt with a duplex printer will not lead to the result, that the first sheet will contain page 1 and 2 and the second page 3 and the blanc back side.

Thank you for your input and ideas.
Topic: every 4th page different footer
Posted: Wednesday, June 19, 2019 11:43:18 AM
Thanks for hint, but I'afraid this won't work either:
result:
- I have now a blanc first page (first unused section).
- same footer on page 2 to 13
- only on last page my different footer.

any other ideas?
Topic: every 4th page different footer
Posted: Friday, June 7, 2019 9:30:18 AM
sorry, can't open your pxf file. When opening Stylevision 2013 says 'unknown version'
(I'm still working with stylevision 2013)
Topic: every 4th page different footer
Posted: Wednesday, June 5, 2019 1:28:22 PM
good idea - but doesn't seam to work, since it wouldn't add a new section when picking the next customer. To play around with this issue I created a demo package as attached (zipped xml, xsd and sps file)
Thanxs for further ideas or hints.
Yours
Topic: every 4th page different footer
Posted: Monday, June 3, 2019 1:23:58 PM
Hi,
I am generating a 4-page-PDF for multiple (n) Customers. So the document length in total is like 4, 8, 12, 16 (and so on) pages long.
The page footer is dynamic (company dependant) and on each page the same. But on every 4th page I don't want to have any footer (blanc).

What I tried (in vain):
- "over printing" the footer with an white table cell
- tried to get access to the "page number"-value

Environment:
fop 1.1
xslt 1.0
Stylevison 2013

Thanks in advance für any idea.


Topic: How to create a newspaper column layout
Posted: Friday, June 19, 2015 11:36:17 AM
Thank to you vlad, I found it - and the solution works for me perfect.
Topic: How to create a newspaper column layout
Posted: Friday, June 19, 2015 7:30:12 AM
I want to create an XSL-template to render a dynamicaly created 2 column pricelist. The items should flow from the bottom of the first column to the top of the second columns (like text flows in a newspaper)

Up to now I don't have any idea how I could do that...

system environment: Stylevision Enterprise V. 2013, XSLT 1.0, fop 0.95

Thanks in advance
Topic: Create PDF ready for printing lables i.e. Avery 3652
Posted: Thursday, August 9, 2012 1:33:40 PM
Thanx Vlad! Helped very much.
(Sorry for late response)

Use of the Altova User Forum(s) is governed by the Altova Terms of Use.