# New-TableHeader

Creates a new table header with specified styling options.

Project

PSWriteHTML

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

[View on GitHub](https://github.com/EvotecIT/PSWriteHTML) [Visit Website](#) [Releases](https://github.com/EvotecIT/PSWriteHTML/releases/tag/v1.41.0) [Changelog](#) [Get package](https://www.powershellgallery.com/packages/PSWriteHTML/1.40.0)

Stars **1,025**

Forks **114**

Open issues 

PowerShell Gallery downloads **7,576,901**

Release **v1.45.0**

Language: PowerShell Updated: 2026-11-19

Command 

**Module**

`PSWriteHTML`

Creates a new table header with specified styling options.

## Syntax

```
New-TableHeader
[-AddRow]
[[-Alignment] <left|center|right|justify>]
[[-BackGroundColor] <String>]
[[-Color] <String>]
[[-ColumnCount] <Int32>]
[[-Direction] <rtl>]
[[-FontFamily] <String>]
[[-FontSize] <Object>]
[[-FontStyle] <normal|italic|oblique>]
[[-FontVariant] <normal|small-caps>]
[[-FontWeight] <String>]
[[-Names] <String[]>]
[[-ResponsiveOperations] <String>]
[[-TextDecoration] <line-through|overline|underline>]
[[-TextTransform] <uppercase|lowercase|capitalize>]
[[-Title] <String>]
[<CommonParameters>]
```

[#](#method-new-tableheader-switchparameter-string-string-string-int32-string-string-object-string-string-string-string-string-string-string-string)

Parameter set: `All Parameter Sets`

## Description

The New-TableHeader function creates a new table header with customizable styling options such as font size, color, alignment, and more.

## Examples

### Example 1

```powershell
New-TableHeader -Names "Name", "Age", "Email" -Title "Employee Information" -Color "black" -BackGroundColor "lightgray" -FontSize 14 -FontWeight "bold" -FontStyle "normal" -FontVariant "normal" -FontFamily "Arial" -Alignment "center" -TextDecoration "none" -TextTransform "uppercase" -Direction "ltr" -AddRow -ColumnCount 3 -Display "all"
Creates a table header with specified column names, title, and styling options.
```

## Parameters

**-AddRow SwitchParameter optional**

Switch parameter to add an additional row to the table header.

**-Alignment String optionalposition: 9**

Specifies the alignment of the table header.

Possible values: `left`, `center`, `right`, `justify`

**-BackGroundColor String optionalposition: 3**

Specifies the background color of the table header.

**-Color String optionalposition: 2**

Specifies the text color of the table header.

**-ColumnCount Int32 optionalposition: 13**

Specifies the number of columns in the table header.

**-Direction String optionalposition: 12**

Specifies the text direction of the table header.

Possible values: `rtl`

**-FontFamily String optionalposition: 8**

Specifies the font family of the table header.

**-FontSize Object optionalposition: 4**

Specifies the font size of the table header.

**-FontStyle String optionalposition: 6**

Specifies the font style of the table header.

Possible values: `normal`, `italic`, `oblique`

**-FontVariant String optionalposition: 7**

Specifies the font variant of the table header.

Possible values: `normal`, `small-caps`

**-FontWeight String optionalposition: 5**

Specifies the font weight of the table header.

Possible values: `normal`, `bold`, `bolder`, `lighter`, `100`, `200`, `300`, `400`, `500`, `600`, `700`, `800`, `900`

**-Names String[] optionalposition: 0**

Specifies an array of column names for the table header.

**-ResponsiveOperations String optionalposition: 14**

Possible values: `all`, `never`, `desktop`, `not-desktop`, `tablet-l`, `tablet-p`, `mobile-l`, `mobile-p`, `min-desktop`, `max-desktop`, `tablet`, `not-tablet`, `min-tablet`, `max-tablet`, `not-tablet-l`, `min-tablet-l`, `max-tablet-l`, `not-tablet-p`, `min-tablet-p`, `max-tablet-p`, `mobile`, `not-mobile`, `min-mobile`, `max-mobile`, `not-mobile-l`, `min-mobile-l`, `max-mobile-l`, `not-mobile-p`, `min-mobile-p`, `max-mobile-p`

**-TextDecoration String optionalposition: 10**

Specifies the text decoration of the table header.

Possible values: `line-through`, `overline`, `underline`

**-TextTransform String optionalposition: 11**

Specifies the text transformation of the table header.

Possible values: `uppercase`, `lowercase`, `capitalize`

**-Title String optionalposition: 1**

Specifies the title of the table header.

## 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](https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_commonparameters).

Evotec API Reference Copyright 2026 Evotec Services

<!-- PowerForge markdown artifact sha256:6D7D2FE9701DC92ACEA382F42E7A5F50FE663CBFD291F90F9A95C9BE5006EEE6 -->
