Bry |
Member |
|
Germany |
|
|
None Specified |
|
Friday, September 23, 2011 |
Tuesday, July 9, 2019 2:47:14 PM |
15 [0.08% of all post / 0.00 posts per day] |
|
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());
}
}
.
|
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.
|
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.
|
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?
|
sorry, can't open your pxf file. When opening Stylevision 2013 says 'unknown version' (I'm still working with stylevision 2013)
|
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
|
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.
|
Thank to you vlad, I found it - and the solution works for me perfect.
|
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
|
Thanx Vlad! Helped very much. (Sorry for late response)
|
|