Skip to content

Instantly share code, notes, and snippets.

@corbob
Created May 29, 2019 18:11
Show Gist options
  • Save corbob/9f22475c8d7d9e514d6784245835bf98 to your computer and use it in GitHub Desktop.
Save corbob/9f22475c8d7d9e514d6784245835bf98 to your computer and use it in GitHub Desktop.
# Works
Param(
[Parameter(mandatory)]
$a,
[ValidateSet(1,2,3,4,5,6,7,8,9)]
$b
)
# doesn't work...
param (
[string]$Str,
[parameter(mandatory)]
[validateset(1,234,6,7,5,3,23)]
$durrrr
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment