Scripts in Subfolders and Pages

Hi gang,

Just tried creating a subfolder in the “scripts” area (which I just called “Subfolder” since I’m just testing) and in it I created a new script called “Get-SubfolderStuff”. The script looks like this:

[pscustomobject] @{
    Name = 'item 1'
    Description = 'The first item'
},
[pscustomobject] @{
    Name = 'item 2'
    Description = 'The second item'
}

I ran the script and confirmed there is pipeline output in the resulting job.

I then edited an existing Page and added a table, pointing the table’s data source at this script.

It won’t show any output. It spins for a few seconds but then says “no data”.

Showing the output from a script in the root folder works fine, but scripts in subfolders don’t seem to work from pages. Is this a known issue?

Cheers,
Matt

Product: PowerShell Universal
Version: 2.5.1

This sounds like a bug. I’ll open an issue for it and take a look.

1 Like