title: How export grid to excel in vaadin?
body: <p>I use vaadin in my project, and i cant understend how export grid to excel.</p>
  
  <p>I have: </p>
  
  <pre><code>Grid&lt;Vlr&gt; gridVlr = new Grid&lt;&gt;("Vlrs"); 
  gridBank.setItems(VlrList); // i used ArrayList
  gridBank.addColumn(Vlr::getVlrId).setCaption("VlrId");
  
  ExportExcelComponentConfiguration&lt;Vlr&gt; componentConfig1
      = new ExportExcelComponentConfigurationBuilder&lt;Vlr&gt;()
          .withGrid(gridVlr)
          .withVisibleProperties(new String[]{"Vlr ID"})
          .withHeaderConfigs(Arrays.asList(
              new ComponentHeaderConfigurationBuilder()
              .withAutoFilter(true)
              .withColumnKeys(new String[]{"Vlr Id"})
              .build()
          ))
          .withIntegerFormattingProperties(Arrays.asList("counter"))
          .withFloatFormattingProperties(Arrays.asList(
              "totalCosts",
              "differenceToMin"
          ))
          .withBooleanFormattingProperties(Arrays.asList("active"))
          //  .withColumnFormatters(columnFormatters)
          .build();
  
  ExportExcelSheetConfiguration&lt;Vlr&gt; sheetConfig1
      = new ExportExcelSheetConfigurationBuilder&lt;Vlr&gt;()
          .withReportTitle("Grid (Default)")
          .withSheetName("Grid (default)")
          .withComponentConfigs(Arrays.asList(componentConfig1))
          .withIsHeaderSectionRequired(Boolean.TRUE)
          .withDateFormat("dd-MMM-yyyy")
          .build();
  
  
  ExportExcelConfiguration&lt;Vlr&gt; config
      = new ExportExcelConfigurationBuilder&lt;Vlr&gt;()
          .withGeneratedBy("Roman")
          .withSheetConfigs(Arrays.asList(sheetConfig1))
          .build();
  
  ExportToExcel exportToExcel = new ExportToExcel(ExportType.XLSX, null);
  
  Button buttonExport = new Button("Export to Excel", clickEvent -&gt; {
      exportToExcel.export();
  });
  
  layout.addComponent(buttonExport);
  </code></pre>
  
  <p>What's my mistake?
   Maybe there is a simpler solution?</p>