mirror of
https://github.com/dfinke/ImportExcel.git
synced 2025-12-10 13:23:29 +00:00
Needs additional work
This commit is contained in:
@@ -171,20 +171,20 @@ function Export-Excel {
|
|||||||
{$_ -is [datetime]} {$targetCell.Style.Numberformat.Format = "m/d/yy h:mm"}
|
{$_ -is [datetime]} {$targetCell.Style.Numberformat.Format = "m/d/yy h:mm"}
|
||||||
}
|
}
|
||||||
|
|
||||||
[ref]$uriResult=$null
|
#[ref]$uriResult=$null
|
||||||
if ([uri]::TryCreate($cellValue, [System.UriKind]::Absolute, $uriResult)) {
|
#if ([uri]::TryCreate($cellValue, [System.UriKind]::Absolute, $uriResult)) {
|
||||||
|
|
||||||
$targetCell.Hyperlink = [uri]$cellValue
|
# $targetCell.Hyperlink = [uri]$cellValue
|
||||||
|
|
||||||
$namedStyle=$ws.Workbook.Styles.NamedStyles | where {$_.Name -eq 'HyperLink'}
|
# $namedStyle=$ws.Workbook.Styles.NamedStyles | where {$_.Name -eq 'HyperLink'}
|
||||||
if(!$namedStyle) {
|
# if(!$namedStyle) {
|
||||||
$namedStyle=$ws.Workbook.Styles.CreateNamedStyle("HyperLink")
|
# $namedStyle=$ws.Workbook.Styles.CreateNamedStyle("HyperLink")
|
||||||
$namedStyle.Style.Font.UnderLine = $true
|
# $namedStyle.Style.Font.UnderLine = $true
|
||||||
$namedStyle.Style.Font.Color.SetColor("Blue")
|
# $namedStyle.Style.Font.Color.SetColor("Blue")
|
||||||
}
|
# }
|
||||||
|
|
||||||
$targetCell.StyleName = "HyperLink"
|
# $targetCell.StyleName = "HyperLink"
|
||||||
}
|
#}
|
||||||
|
|
||||||
$ColumnIndex += 1
|
$ColumnIndex += 1
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user