Hi, I know I am asking bunch of questions. Sorry about that. Trying to get a couple dashboards knocked out so I can show our team how useful PSU can be.
Can a New-UDLink go inside a table column? I seem to be able to place text in the table column but not a New-UDLink
I tried this and it didnt work even though i know $CacheDatalist.CI and $CacheDatalist.ciURL has the text and url arrays as i can run that part of the code in powershell command prompt.
tartup: Cannot process argument transformation on parameter 'Text'. Cannot convert value to type System.String.
Startup: at <ScriptBlock>, C:\ProgramData\UniversalAutomation\Repository\dashboards\version\version.ps1: line 231
at New-UDTable<Process>, C:\ProgramData\PowerShellUniversal\Server\Modules\UniversalDashboard\4.1.0\UniversalDashboard.MaterialUI.psm1: line 5780
at <ScriptBlock>, C:\ProgramData\UniversalAutomation\Repository\dashboards\version\version.ps1: line 241
at <ScriptBlock>, <No file>: line 1
Startup: at System.Management.Automation.ParameterBinderBase.BindParameter(CommandParameterInternal parameter, CompiledCommandParameter parameterMetadata, ParameterBindingFlags flags)
at System.Management.Automation.CmdletParameterBinderController.BindParameter(CommandParameterInternal argument, MergedCompiledCommandParameter parameter, ParameterBindingFlags flags)
at System.Management.Automation.CmdletParameterBinderController.BindParameter(UInt32 parameterSets, CommandParameterInternal argument, MergedCompiledCommandParameter parameter, ParameterBindingFlags flags)
at System.Management.Automation.CmdletParameterBinderController.BindNamedParameter(UInt32 parameterSets, CommandParameterInternal argument, MergedCompiledCommandParameter parameter)
at System.Management.Automation.ParameterBinderController.BindNamedParameters(UInt32 parameterSets, Collection`1 arguments)
at System.Management.Automation.CmdletParameterBinderController.BindCommandLineParametersNoValidation(Collection`1 arguments)
at System.Management.Automation.CmdletParameterBinderController.BindCommandLineParameters(Collection`1 arguments)
at System.Management.Automation.CommandProcessor.BindCommandLineParameters()
at System.Management.Automation.CommandProcessor.Prepare(IDictionary psDefaultParameterValues)
at System.Management.Automation.CommandProcessorBase.DoPrepare(IDictionary psDefaultParameterValues)
at System.Management.Automation.Internal.PipelineProcessor.Start(Boolean incomingStream)
at System.Management.Automation.Internal.PipelineProcessor.SynchronousExecuteEnumerate(Object input)
Basically with New-UDTable the data passed to it becomes available in $EventData, so you need the data available in the inital data you put in New-UDTable.
I don’t have access to a system where I am currently, but look at the docs here: Table - PowerShell Universal See the example with $EventData