donnabelle07
New Member
HI,
can anyone please help me on pdf include. I am trying to use a template for pdf and fill out the data on a new pdf file. However if I have 3 records the new pdf file will only create the first record.
Here is my code:
IF vcont2 = 1 THEN DO:
RUN pdf_reset_all.
RUN pdf_new("Spdf",chFile2). /* new pdf file */
END.
RUN pdf_open_PDF("Spdf",chFile,CHID). /* Open Template PDF */
RUN DoNewPage2(vCont2,CHID).
RUN pdf_close("Spdf").
PROCEDURE DoNewPage2.
DEFINE INPUT PARAMETER vcont2 AS INTEGER NO-UNDO.
DEFINE INPUT PARAMETER CH_ID AS CHARACTER NO-UNDO.
I_PAGE = I_PAGE + 1.
RUN pdf_new_page("Spdf").
RUN pdf_use_PDF_page("Spdf",vcont2,CH_ID).
RUN pdf_fill_text("Spdf", "SchoolName",chSchoolName, "Align=left").
END PROCEDURE.
Thanks,
Donna
can anyone please help me on pdf include. I am trying to use a template for pdf and fill out the data on a new pdf file. However if I have 3 records the new pdf file will only create the first record.
Here is my code:
IF vcont2 = 1 THEN DO:
RUN pdf_reset_all.
RUN pdf_new("Spdf",chFile2). /* new pdf file */
END.
RUN pdf_open_PDF("Spdf",chFile,CHID). /* Open Template PDF */
RUN DoNewPage2(vCont2,CHID).
RUN pdf_close("Spdf").
PROCEDURE DoNewPage2.
DEFINE INPUT PARAMETER vcont2 AS INTEGER NO-UNDO.
DEFINE INPUT PARAMETER CH_ID AS CHARACTER NO-UNDO.
I_PAGE = I_PAGE + 1.
RUN pdf_new_page("Spdf").
RUN pdf_use_PDF_page("Spdf",vcont2,CH_ID).
RUN pdf_fill_text("Spdf", "SchoolName",chSchoolName, "Align=left").
END PROCEDURE.
Thanks,
Donna