Get-ADGroup Help

This topic contains 1 reply, has 2 voices, and was last updated by Profile photo of Dave Wyatt Dave Wyatt 2 years, 9 months ago.

  • Author
  • #18736
    Profile photo of Kelly Farrell
    Kelly Farrell

    I would like to get group membership from certain groups run against User OU. Is it possible to set the group and User OU mandatory so it prompts the user for which groups they want and which User OU to search membership against?

  • #18737
    Profile photo of Dave Wyatt
    Dave Wyatt

    You can't modify the actual Get-ADGroup cmdlet to make parameters mandatory if they're not mandatory already, but what you can do is write a function which has the parameter behavior you want, and call Get-ADGroup from within that function.

You must be logged in to reply to this topic.