Skip to content

Latest commit

 

History

History
246 lines (194 loc) · 6.14 KB

File metadata and controls

246 lines (194 loc) · 6.14 KB
external help file PSWriteOffice-help.xml
Module Name PSWriteOffice
online version https://github.com/EvotecIT/PSWriteOffice
schema 2.0.0

Set-OfficeExcelInternalLinksByHeader

SYNOPSIS

Converts cells under a header into internal workbook links.

SYNTAX

ContextUsedRange (Default)

Set-OfficeExcelInternalLinksByHeader [-Header] <string> [-DestinationSheetScript <scriptblock>] [-DisplayScript <scriptblock>] [-TargetAddress <string>] [-NoStyle] [-PassThru] [<CommonParameters>]

DocumentUsedRange

Set-OfficeExcelInternalLinksByHeader [-Header] <string> -Document <ExcelDocument> [-Sheet <string>] [-SheetIndex <int>] [-DestinationSheetScript <scriptblock>] [-DisplayScript <scriptblock>] [-TargetAddress <string>] [-NoStyle] [-PassThru] [<CommonParameters>]

DocumentTable

Set-OfficeExcelInternalLinksByHeader [-Header] <string> -Document <ExcelDocument> -TableName <string> [-Sheet <string>] [-SheetIndex <int>] [-DestinationSheetScript <scriptblock>] [-DisplayScript <scriptblock>] [-TargetAddress <string>] [-NoStyle] [-PassThru] [<CommonParameters>]

DocumentRange

Set-OfficeExcelInternalLinksByHeader [-Header] <string> -Document <ExcelDocument> -Range <string> [-Sheet <string>] [-SheetIndex <int>] [-DestinationSheetScript <scriptblock>] [-DisplayScript <scriptblock>] [-TargetAddress <string>] [-NoStyle] [-PassThru] [<CommonParameters>]

ContextTable

Set-OfficeExcelInternalLinksByHeader [-Header] <string> -TableName <string> [-DestinationSheetScript <scriptblock>] [-DisplayScript <scriptblock>] [-TargetAddress <string>] [-NoStyle] [-PassThru] [<CommonParameters>]

ContextRange

Set-OfficeExcelInternalLinksByHeader [-Header] <string> -Range <string> [-DestinationSheetScript <scriptblock>] [-DisplayScript <scriptblock>] [-TargetAddress <string>] [-NoStyle] [-PassThru] [<CommonParameters>]

DESCRIPTION

Converts cells under a header into internal workbook links.

EXAMPLES

EXAMPLE 1

PS>ExcelSheet 'Summary' { Set-OfficeExcelInternalLinksByHeader -Header 'Sheet' }

Uses the used range header row to find the Sheet column and converts its values into internal links.

PARAMETERS

-DestinationSheetScript

Optional mapping from cell text to destination sheet name.

Type: ScriptBlock
Parameter Sets: ContextUsedRange, DocumentUsedRange, DocumentTable, DocumentRange, ContextTable, ContextRange
Aliases: None
Possible values: 

Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: True

-DisplayScript

Optional mapping from cell text to display text.

Type: ScriptBlock
Parameter Sets: ContextUsedRange, DocumentUsedRange, DocumentTable, DocumentRange, ContextTable, ContextRange
Aliases: None
Possible values: 

Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: True

-Document

Workbook to operate on outside the DSL context.

Type: ExcelDocument
Parameter Sets: DocumentUsedRange, DocumentTable, DocumentRange
Aliases: None
Possible values: 

Required: True
Position: named
Default value: None
Accept pipeline input: True (ByValue)
Accept wildcard characters: True

-Header

Header text to locate.

Type: String
Parameter Sets: ContextUsedRange, DocumentUsedRange, DocumentTable, DocumentRange, ContextTable, ContextRange
Aliases: None
Possible values: 

Required: True
Position: 0
Default value: None
Accept pipeline input: False
Accept wildcard characters: True

-NoStyle

Skip hyperlink styling (blue + underline).

Type: SwitchParameter
Parameter Sets: ContextUsedRange, DocumentUsedRange, DocumentTable, DocumentRange, ContextTable, ContextRange
Aliases: None
Possible values: 

Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: True

-PassThru

Emit the worksheet after creating links.

Type: SwitchParameter
Parameter Sets: ContextUsedRange, DocumentUsedRange, DocumentTable, DocumentRange, ContextTable, ContextRange
Aliases: None
Possible values: 

Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: True

-Range

Restrict linking to a specific A1 range whose first row contains headers.

Type: String
Parameter Sets: DocumentRange, ContextRange
Aliases: None
Possible values: 

Required: True
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: True

-Sheet

Worksheet name when using Document.

Type: String
Parameter Sets: DocumentUsedRange, DocumentTable, DocumentRange
Aliases: None
Possible values: 

Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: True

-SheetIndex

Worksheet index (0-based) when using Document.

Type: Nullable`1
Parameter Sets: DocumentUsedRange, DocumentTable, DocumentRange
Aliases: None
Possible values: 

Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: True

-TableName

Restrict linking to a named table.

Type: String
Parameter Sets: DocumentTable, ContextTable
Aliases: None
Possible values: 

Required: True
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: True

-TargetAddress

Destination cell on the target sheet.

Type: String
Parameter Sets: ContextUsedRange, DocumentUsedRange, DocumentTable, DocumentRange, ContextTable, ContextRange
Aliases: None
Possible values: 

Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: True

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

  • OfficeIMO.Excel.ExcelDocument

OUTPUTS

  • OfficeIMO.Excel.ExcelSheet

RELATED LINKS

  • None