| external help file | Module Name | online version | schema |
|---|---|---|---|
PSWriteOffice-help.xml |
PSWriteOffice |
2.0.0 |
Creates a new Excel workbook using the DSL.
New-OfficeExcel [-FilePath] <string> [[-Content] <scriptblock>] [-AutoSave] [-NoSave] [-Open] [-PassThru] [<CommonParameters>]Creates a new Excel workbook using the DSL.
PS>New-OfficeExcel -Path .\report.xlsx { ExcelSheet 'Data' { ExcelCell -Address 'A1' -Value 'Region' } }Creates report.xlsx and writes “Region” into cell A1 on the Data worksheet.
Opt into OfficeIMO automatic saves during operations.
Type: SwitchParameter
Parameter Sets: __AllParameterSets
Aliases: None
Possible values:
Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: TrueDSL scriptblock describing workbook content.
Type: ScriptBlock
Parameter Sets: __AllParameterSets
Aliases: None
Possible values:
Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: TrueDestination path for the workbook.
Type: String
Parameter Sets: __AllParameterSets
Aliases: Path
Possible values:
Required: True
Position: 0
Default value: None
Accept pipeline input: False
Accept wildcard characters: TrueSkip saving the workbook after running the DSL.
Type: SwitchParameter
Parameter Sets: __AllParameterSets
Aliases: None
Possible values:
Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: TrueOpen the workbook in Excel after saving.
Type: SwitchParameter
Parameter Sets: __AllParameterSets
Aliases: None
Possible values:
Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: TrueEmit a FileInfo for convenience.
Type: SwitchParameter
Parameter Sets: __AllParameterSets
Aliases: None
Possible values:
Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: TrueThis cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
None
System.Object
- None