Multi-string script parameters don't show options, throw error

A fix for this issue has been implemented in version 2026.3.1
Implemented

Multi-string script parameters don't show options, throw error

avatar

I have many scripts that have an array type (i.e. [string[]]) with a ValidateSet decorator. In the latest release when I'm editing existing schedules the set parameters don't populate and the drop down selector is not working.

All Comments (5)

avatar

Hello @realslacker

Thank you for reporting this.

I understand that when editing existing schedules, parameters defined as [string[]] with a ValidateSet are no longer populating their previously selected values and the dropdown selector is not working correctly.

To help us narrow this down, could you please provide:

• Your exact PowerShell Universal version and build.
• The last PSU version where this worked correctly, if known.
• A minimal example of the affected parameter definition, preferably just the relevant param() block.
• The exact error message or a screenshot showing the error.
• Whether creating a new schedule works correctly and the problem only occurs when editing an existing schedule.

Once we have those details, we can compare the behavior and determine whether we can reproduce it consistently.

Because this is a public forum, please sanitize all evidence before posting. Remove credentials, tokens, license keys, cookies, private keys, full connection strings, email addresses, usernames, customer data, tenant or account identifiers, internal domains, hostnames, IP addresses, and private URLs. Please do not upload unredacted HAR files, memory dumps, database backups, or complete configuration files to this public thread.

Best regards,
Ruben Tapia

avatar

I'm seeing these all on version 2026.2.5.

Weirdness on [int] params

Example Script:

param( [int] $IntParam = 30 )


Repro:

  1. Create a schedule, observe that initially the schedule can be edited and the value remains 30.
  2. Reload schedules.ps1 configuration file from Settings > Files
  3. Wait several seconds for schedules to be reloaded complete
  4. Edit the schedule and observe the value is now 0 (Note that the schedules.ps1 still reflects 30)


Weirdness on [string[]] params - Example 1

Example Script:

param( [string[]] $MultipleStrings = @( 'test', 'test' ) )


Repro:

  1. Create a schedule, observe that the default value is not filled in
  2. Enter test and press enter to fill in value
  3. Enter test again, note that you cannot fill in the same value twice


Weirdness on [string[]] params - Example 2

Example Script:

param( [string[]] $MultipleStrings = @( 'test1', 'test2' ) )


Repro:

  1. Create a schedule, observe that the default value is not filled in
  2. Enter multiple values pressing enter after each to add to list
  3. Save the schedule
  4. Observer "An Error Occured" appears instead of the schedules page
  5. Refresh
  6. Observe that the schedule was created and parameters are populated
  7. Edit the schedule, remove values and save
  8. Observe that the schedule was updated
  9. Edit the schedule, add a value and press enter to add it to the list
  10. Observe that the parent page shows "An Error Occurred" but that the form is not dismissed, page is unresponsive


Weirdness on [string[]] params - Example 3

Example Script:

param( [ValidateSet( 'test1', 'test2' )][string[]] $MultipleStrings = @( 'test1', 'test2' ) )


Repro:

  1. Create a schedule, observe that the default value is not filled in
  2. Enter multiple valid values choosing from the drop down or typing in and pressing enter
  3. Save the schedule
  4. Edit the schedule, remove the last value
  5. Observe that the drop down now only shows the first value as an option
  6. Save the schedule
  7. Edit the schedule, remove all values
  8. Observe that the drop down has no options
  9. Manually re-enter a valid value and press enter
  10. Observe that the parent page shows "An Error Occurred" but that the form is not dismissed, page is unresponsive


Weirdness on [pscredential] params

Example Script:

param( [pscredential] $ExampleCredential )


Repro:

  1. Create a schedule filling in the credential parameter
  2. Save the schedule
  3. Observe that the schedule can be edited and the parameter remains filled
  4. Reload the schedules.ps1 file
  5. Observe that the parameter is now empty when editing the schedule


avatar

The UI also seems very sluggish to load schedules and scripts. I'm migrating from v4 and it's so much slower...

avatar

I'm also noticing that [string[]] parameters with multiple value defaults are not populated when running a script unless the ValidateSet is used.

avatar

I've opened a ticket to investigate this. It seems fairly straightforward, but we will circle back if we need more information. Thank you!

A fix for this issue has been implemented in version 2026.3.1