Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- try {
- com.cete.dynamicpdf.Document objDocument = new com.cete.dynamicpdf.Document();
- Page objPage = new Page(PageSize.LETTER, PageOrientation.PORTRAIT,
- 54.0f);
- objDocument.getPages().add(objPage);
- objPage.getElements().add(new Label(paragraphText, 0, 0, 500, 350,
- com.cete.dynamicpdf.Font.getHelvetica(), 18, TextAlign.LEFT));
- objPage.getElements().add(new com.cete.dynamicpdf.pageelements.Image(downloadDir+"/ibwave_logo.jpg", 0, 300));
- Table2 table = new Table2(0, 400, 500, 300);
- table.getColumns().add(50);
- table.getColumns().add(50);
- table.getColumns().add(50);
- Row2 row = table.getRows().add(50);
- row.getCells().add("1.0");
- row.getCells().add("1.1");
- row.getCells().add("1.2");
- row = table.getRows().add(50);
- row.getCells().add("2.0");
- row.getCells().add("2.1");
- row.getCells().add("2.2");
- objPage.getElements().add(table);
- objDocument.draw(downloadDir+"/test2.pdf");
- } catch (Exception e) {
- e.printStackTrace();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement