JamesBowen
19+ years progress programming and still learning.
I have the following code to set the X and Y positions and then uses the pdf_Text procedure output a string of text.
I could have completely misunderstand of what pdf_set_textX & pdf_set_textY do.
Running the pdf_set_textX & pdf_set_textY don't seam to do anything to affect the positioning of the outputted text.
I could have completely misunderstand of what pdf_set_textX & pdf_set_textY do.
Running the pdf_set_textX & pdf_set_textY don't seam to do anything to affect the positioning of the outputted text.
Code:
{pdf_inc.i }
RUN pdf_new ("Spdf","./X-POS-TEST.pdf").
RUN pdf_new_page("Spdf").
RUN pdf_set_textX("Spdf", 10).
RUN pdf_text("Spdf", "Test 1. I should be at column 10 pdf_TextX=" + STRING(pdf_TextX("Spdf"))).
RUN pdf_skip("Spdf").
RUN pdf_set_textX("Spdf", 200).
RUN pdf_text("Spdf", "Test 2. I should be at column 200 pdf_TextX=" + STRING(pdf_TextX("Spdf"))).
RUN pdf_skip("Spdf").
RUN pdf_set_textY("Spdf", 50).
RUN pdf_text("Spdf", "Test 3. I should on Row 50 pdf_TextY=" + STRING(pdf_TextY("Spdf")) ).
RUN pdf_skip("Spdf").
RUN pdf_skip("Spdf").
DEFINE VARIABLE iYLoop AS INTEGER NO-UNDO.
DEFINE VARIABLE iXLoop AS INTEGER NO-UNDO.
DO iYloop = 1 TO 10:
RUN pdf_set_textY("Spdf", iYloop).
DO iXLoop = 1 TO 10:
RUN pdf_set_textX("Spdf", iXLoop).
RUN pdf_text("Spdf", STRING(iYloop * iXLoop)).
MESSAGE STRING(iYloop * iXLoop).
END.
END.
RUN pdf_close("Spdf").