Example: print method

This example prints the sheet 1 to 7 of the spreadsheet for one copy.

try {
  Application application = Application.getInstance();
  Spreadsheets spreadsheets = application.getSpreadsheets();
  Spreadsheet spreadsheet = spreadsheets.openSpreadsheet("D:\\test.ods", true);
  spreadsheet.print(1, "1-7", true);
} catch(Exception e) {
  e.printStackTrace();
}

Related information

print method