# Set-OfficeExcelUrlLinks

Converts cells in a range into external URL hyperlinks.

Project

PSWriteOffice

PowerShell document automation across OfficeIMO's document, spreadsheet, presentation, PDF, Project, Access, EPUB, invoicing, and conversion engines.

[View on GitHub](https://github.com/EvotecIT/OfficeIMO/tree/master/PowerShell/PSWriteOffice) [Visit Website](#) [Releases](https://github.com/EvotecIT/PSWriteOffice/releases/tag/v3.0.5) [Changelog](#) [Get package](https://www.powershellgallery.com/packages/PSWriteOffice/0.2.0)

Stars **725**

Forks **84**

Open issues **3**

Total downloads **5,231,343**

Release **OfficeIMO-v3.6.2**

Language: C# Updated: 2026-11-23

Cmdlet 

Aliases: ExcelUrlLinks

**Module**

`PSWriteOffice`

**Aliases**

`ExcelUrlLinks`

**Inputs**

`OfficeIMO.Excel.ExcelDocument`

**Outputs**

`OfficeIMO.Excel.ExcelSheet`

**Source**

[SetOfficeExcelUrlLinksCommand.cs:17](https://github.com/EvotecIT/PSWriteOffice/blob/main/Sources/PSWriteOffice/Cmdlets/Excel/SetOfficeExcelUrlLinksCommand.cs#L17) 

Converts cells in a range into external URL hyperlinks.

## Syntax

```
Set-OfficeExcelUrlLinks
[-NoStyle]
[-PassThru]
[-Range] <String>
[-TitleScript <ScriptBlock>]
-UrlScript <ScriptBlock>
[<CommonParameters>]
```

[#](#method-set-officeexcelurllinks-switchparameter-switchparameter-string-scriptblock-scriptblock)

Parameter set: `Context`

```
Set-OfficeExcelUrlLinks
-Document <ExcelDocument>
[-NoStyle]
[-PassThru]
[-Range] <String>
[-Sheet <String>]
[-SheetIndex <Int32>]
[-TitleScript <ScriptBlock>]
-UrlScript <ScriptBlock>
[<CommonParameters>]
```

[#](#method-set-officeexcelurllinks-exceldocument-switchparameter-switchparameter-string-string-int32-scriptblock-scriptblock)

Parameter set: `Document`

## Examples

### Link a summary range to RFC pages.

```powershell
ExcelSheet 'Summary' { Set-OfficeExcelUrlLinks -Range 'D2:D10' -UrlScript { param($text) "https://datatracker.ietf.org/doc/html/$text" } }
```

Turns each non-empty cell in D2:D10 into an external hyperlink.

## Parameters

**-NoStyle SwitchParameter optional**

Skip hyperlink styling (blue + underline).

**-PassThru SwitchParameter optional**

Emit the worksheet after creating links.

**-Range String requiredposition: 0**

A1 range containing values to convert into external links.

**-TitleScript ScriptBlock optional**

Optional mapping from cell text to display text.

**-UrlScript ScriptBlock required**

Maps the cell text to a URL.

**-Document ExcelDocument requiredpipeline: True (ByValue)sets: Document**

Workbook to operate on outside the DSL context.

**-Sheet String optionalsets: Document**

Worksheet name when using Document.

**-SheetIndex Int32 optionalsets: Document**

Worksheet index (0-based) when using Document.

## 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:EE62D5E5044D6EB0B0D5EC948262C40B813EB57D0D76E4B5C1665BE978408186 -->
