I've used advanced parameter handling to support multiple parameter sets. Is there any pre-defined variable or way to determine which parameter set has been used to call the script?
e.g. something like
if($parameterSet -eq "set1") { ... } elseif ($parameterSet -eq "set2") { ... }
?
Check the $PSCmdlet variable:
$PSCmdlet.ParameterSetName