How to remove Vaadin Spreadsheets add new sheet (+) button

Is there a way to remove the (+) button on the bottom left corner of Vaadin Spreadsheets.

I want to implement a Report like functionality with tabs enabled but I dont want the user adding sheets.

Any ideas?

You could try adding this to your theme:

  .add-new-tab {
    display:none !important;

Hi Anna,

That did the trick, but I think it would be better to manage from the server side as well.
Also there is very big space until the first tab starts, this is because sheet-tabsheet-options is always visible even if there is no requirement from scrolling. Shouldn’t that be visible only when tab scrolling is required?

If you want to remove the options altogether, try:

.v-spreadsheet .sheet-tabsheet .sheet-tabsheet-options { display:none; } .v-spreadsheet .sheet-tabsheet .sheet-tabsheet-container { left: 0; } I don’t think it’s possible to make the hiding optional with css alone, though. You could perhaps add a feature request for that in

Hi, this works fine for me.

  • first, create a XSSFWorkbook workbook
  • set workbook lockStructure
  • add some sheets
  • create spreadsheet with this workbook

for example:

XSSFWorkbook workbook = new XSSFWorkbook();
// you could set password if you need
// workbook.setWorkbookPassword("pass", null);  
Sheet sheet1 = workbook.createSheet("My Sheet1");
Sheet sheet2 = workbook.createSheet("My Sheet2");
spreadsheet = new Spreadsheet(workbook);

This is very helpful for me.