Re: Changing PdfPTable width from RPGLE using iText
Jon Paris <[email protected]> Sat, 8 Apr 2023 12:02:22 -0400
| Newsgroups | gmane.comp.lang.as400.java |
|---|---|
| Message-ID | <[email protected]> |
You haven't shown how you do the call - did you include the object as the first parameter? I would expect it to be: pTable_setWidthPercentage( newTable : 90 ); Jon P. > On Apr 7, 2023, at 2:39 PM, Rich Dotson <[email protected]> wrote: > > We use the techniques from the Advanced Integrated RPG book by Thomas Snyder to create PDFs with RPG. > > I am trying to modify the width of a table inside a .pdf using using RPGLE. I would like to use the 'setWidthPercentage' method to adjust the table size but I can not get it to work in my RPGLE program. It defaults the table width to 80% of the page and I need to increase it sightly. > > I have found the Java code to set the width of the table. > > table.setWidthPercentage(90); > > > The problem I am having is translating that code to RPG. > > I am able to create a two column table using: > > newTable = new_pdfptable(2); > > > I tried defining the 'setWidthPercentage' using: > > dcl-pr pTable_setWidthPercentage ExtProc(*JAVA > :'com.lowagie.text.pdf.PdfPTable' > :'setWidthPercentage'); > prWidthPct int(10) value; > end-pr; > > > When I try to use it I get the 'java.lang.NoSuchMethodError' message. The documentation I've found online states that the 'setWidthPercentage' method is in that .jar file version we have loaded. > > Any suggestions on how I can change the size of the table? > > Thanks, -Rich > > > -- > This is the Java Programming on and around the IBM i (JAVA400-L) mailing list > To post a message email: [email protected] > To subscribe, unsubscribe, or change list options, > visit: https://lists.midrange.com/mailman/listinfo/java400-l > or email: JAVA400-L-request-+hD5IHI5Xscn3HwCXmMcX9BPR1lH4CV8@public.gmane.org > Before posting, please take a moment to review the archives > at https://archive.midrange.com/java400-l. -- This is the Java Programming on and around the IBM i (JAVA400-L) mailing list To post a message email: [email protected] To subscribe, unsubscribe, or change list options, visit: https://lists.midrange.com/mailman/listinfo/java400-l or email: JAVA400-L-request-+hD5IHI5Xscn3HwCXmMcX9BPR1lH4CV8@public.gmane.org Before posting, please take a moment to review the archives at https://archive.midrange.com/java400-l.