// Create a new workbook Workbook workbook = new Workbook(); // Load template file from resource InputStream templateFile = this.getResourceStream("xlsx/Template_LeaseRentalApplicationForm.xlsx"); workbook.open(templateFile); //No data needed //Invoke to process the template workbook.processTemplate(); // Save to a pdf file workbook.save("LeaseRentalApplicationForm.pdf");