Skip to content

Csv Export: Restructure saveAsCsV() function #404

@erjoh001

Description

@erjoh001

I wanted to export out of a document with a few sheets the single sheets as csv. There i struggled with some issues:

  1. the definition of the csvFileName is based on the sheetName and an underscore. There is no way to give the csv-File an completely new name without this both components.
  2. the delimeter is hard coded. Sometimes you want to change it.
  3. the function is looping through all sheetNames. Actually there is no way to select a singleSheet and just write this to a csv.

Suggestions:

  1. adding a bool to give the oportunity for setting a fixed Name, if false use the existing logic.
  2. adding an argument for the delimeter that is passed to write.csv(delimeter)
  3. if there is an activeSheet which was set with document.setActiveSheet() use this for the csv-Export and dont loop through all sheets.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions