how do you create a link in a specific cell in a new-udtable
i have tried using new-udlink as per below with no luck
any feedback much appreciated thanks
$data = @(
@{Query="Link1"; Result = New-UDLink -Text "Link1" -Url "https://www.poshtools.com"}
@{Query="Link2"; Result = New-UDLink -Text 'Link2' -OnClick (
Invoke-UDRedirect http://www.ironmansoftware.com
)
}
)
New-UDTable -Data $Data
Product: PowerShell Universal
Version: 1.5.21
adam
2
Hey @Srichman0128,
You’ll want to use custom column rendering to achieve this: Table - PowerShell Universal
From my understanding this would be used for every row in the column is it possible to apply to only 1 row or cell?
adam
4
You can’t do it for a single cell but you can put some logic in the render to return the custom hyperlink for some rows.
New-UDTableColumn -Render {
if ($EventData.MyProperty -eq 'Cool') {
New-UDLink
} else {
$EventData.MyProperty
}
}
1 Like