IMPORTANT ANNOUNCEMENT

These forums were permanently set to read-only mode on July 20, 2022. From that day onwards, no new posting or comment is allowed on the site, but the historical content remains intact and searchable.

A new location for posting questions about PlanetPress Suite is now available:

OL Learn - PlanetPress Classic (opens in new tab)

Topic Options
#57164 - 07/30/19 03:38 PM Press Talk and PDF object margin
dstauder Offline
OL User

Registered: 06/28/02
Posts: 78
Loc: St. Louis, Missouri USA
Hello,

I am retrieving a PDF with variable numbers of pages onto a virtual page (page does not eject). A few of the PDFs have a 0.25" margin. I need to move those pages another 0.25" to the left. When I move the PDF over 0.25" the virtual page of the PDF it does move to the left 0.25" for the first page, however the rest of the pages go back to the 0.0" on the output and thus go back to the 0.25" margin.

I want to have all the pages in the PDF move over 0.25". I could write a VB Script to do this in the workflow but I would rather accomplish this with the Press Talk that is pulling in the PDFs in the first place. Below is the PTalk syntax that I am currently running.

*********************************************************************
define(&i,integer,1)
define(&PDFName,string,GetMeta('DataFile[0]', 1, 'Job.Group.Document'))

For(&i,1,1,pdfpagecount(&PDFName))
showpdf(&PDFName,&i,0,0)
if(&i<pdfpagecount(&PDFName))

showpage()
endif()
endfor()

********************************************************************

Your assistance is greatly appreciated.

Thank you,

Dan Stauder

Top
#57168 - 07/31/19 09:05 AM Re: Press Talk and PDF object margin [Re: dstauder]
Jean-Cédric Offline
OL Expert

Registered: 10/03/16
Posts: 681
Loc: Québec, Canada
Try this:

Code:
For(&i,1,1,pdfpagecount(&PDFName))
  translate(0.25,0)
  showpdf(&PDFName,&i,0,0)
  
  if(&i<pdfpagecount(&PDFName))
    showpage()
  endif()
endfor()
_________________________
♪♫♪♫
99 frigging bugs in my code
99 frigging bugs
Take one down
Code around
127 frigging bugs in my code
♪♫♪♫

Top
#57169 - 08/01/19 12:41 PM Re: Press Talk and PDF object margin [Re: dstauder]
dstauder Offline
OL User

Registered: 06/28/02
Posts: 78
Loc: St. Louis, Missouri USA
Thank you. It seems to have worked. I will be testing this this afternoon to make sure that all the pages are correct.

I appreciate your help.

Dan

Top
#57170 - 08/01/19 12:41 PM Re: Press Talk and PDF object margin [Re: dstauder]
dstauder Offline
OL User

Registered: 06/28/02
Posts: 78
Loc: St. Louis, Missouri USA
Thank you. It seems to have worked. I will be testing this this afternoon to make sure that all the pages are correct.

I appreciate your help.

Dan

Top