Colvis plugin and buttons/exports

Colvis plugin and buttons/exports

yetyet Posts: 43Questions: 17Answers: 1

We are using the colvis plugin and the exporter plugins for exporting to excel and PDF.
The exporter plugins do not respect the visibility/invisibility of columns into account and always export all columns.
Is it possible to configure the exporters to export only the visibile columns?

Answers

  • rf1234rf1234 Posts: 3,021Questions: 88Answers: 421

    If you are using the latest Editor version the first option makes sure only the visible columns are exported the second option makes sure that all rows (not only the selected ones get exported). If you only want the selected rows to be exported just delete the second option.

    exportOptions: {
    columns: ':visible',
    modifier: { selected: null },

  • allanallan Posts: 63,689Questions: 1Answers: 10,500 Site admin

    See also this example for live running code of what @rf1234 mentions.

    Allan

This discussion has been closed.