Project

PSWriteHTML

Generate HTML reports, dashboards, and emails from PowerShell without writing HTML, CSS, or JavaScript.

Stars 1,023
Forks 115
Open issues 54
PowerShell Gallery downloads 7,576,901
Release v1.45.0
Language: PowerShell Updated: 2026-11-03
Command

New-TableButtonCSV

Module
PSWriteHTML

Creates a new table button for exporting data to CSV with customizable options.

Syntax

New-TableButtonCSV
[[-ButtonName] <String>]
[-DisableBOM]
[[-Extension] <String>]
[[-FieldBoundary] <String>]
[[-FieldSeparator] <String>]
[[-FileName] <String>]
[[-Title] <String>]
[<CommonParameters>]
#
Parameter set: All Parameter Sets

Description

This function creates a new table button for exporting data to CSV with customizable options. It allows users to specify the button title, file name, and other settings for CSV export.

Examples

Example 1

New-TableButtonCSV -Title "Export to CSV" -FileName "data" -FieldSeparator "," -FieldBoundary "'"

Description ----------- Creates a new table button with the title "Export to CSV", exports data to a CSV file named "data.csv" with comma as the field separator and single quote as the field boundary.

Parameters

-ButtonName String optionalposition: 1
The text to be displayed on the button. Default value is 'CSV'.
-DisableBOM SwitchParameter optional
Switch to disable Byte Order Mark (BOM) in the exported CSV file.
-Extension String optionalposition: 2
The file extension for the exported CSV file. Default value is '.csv'.
-FieldBoundary String optionalposition: 5
The character used to enclose fields in the CSV file. Default value is '"'.
-FieldSeparator String optionalposition: 4
The separator character for fields in the CSV file. Default value is ';'.
-FileName String optionalposition: 3
The name of the exported CSV file.
-Title String optionalposition: 0
The title to be displayed when hovering over the button.

Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see about_CommonParameters.