Select and compare challenge

Welcome Forums General PowerShell Q&A Select and compare challenge

Viewing 1 reply thread
  • Author
    Posts
    • #257330
      Participant
      Topics: 5
      Replies: 1
      Points: 67
      Rank: Member

      We have a security group, that has a 90 day pw policy.
      In this group , all the accounts in Specific ou’s need to be a member

      Currently there 299 Accounts in de ou’s and 42 members of the security group ($Adgroup

      I am able to get the ADusers of the ou’s   ($Users)
      I can find oput , who is already a member ($Members)

      I canNOt get powershell to tell me who needs to added to $Adgroup ( $Notmember)

      With $Notmember I need powerhell to tell me, what ad account has a expired Password on <=today
      Because the $notmember has now a 185 days Pw Policy , they are going to a 90 day PW Policy.
      That means there might be accounts that will have there PassWord expired and do not know this in time.
      We want them to recieve a mail and be able to change there PW in time.

      This is my script, i look forward to some feedback

       

    • #257345
      Participant
      Topics: 1
      Replies: 85
      Points: 387
      Helping Hand
      Rank: Contributor

      Consider the following:

      When you pipe to Export-Csv, none of the output objects are returned to the success stream. Therefore, variables won’t be updated when using the syntax $variable = Export-Csv. The same applies when piping to Out-GridView.

Viewing 1 reply thread
  • You must be logged in to reply to this topic.