// For complete examples and data files, please go to https://github.com/aspose-cells/Aspose.Cells-for-Java // The path to the documents directory. String dataDir = Utils.getSharedDataDir(SaveWorkbookToTextCSVFormat.class) + "loading_saving/"; // Load your source workbook Workbook workbook = new Workbook(dataDir + "book1.xls"); // Text save options. You can use any type of separator TxtSaveOptions opts = new TxtSaveOptions(); opts.setSeparator('\t'); opts.setExportAllSheets(true); //Save entire workbook data into file workbook.save(dataDir + "SWTTextCSVFormat-out.txt", opts); // Print message System.out.println("Excel to Text File Conversion performed successfully.");