Writing attribute changes to an output file

Welcome Forums General PowerShell Q&A Writing attribute changes to an output file

Viewing 4 reply threads
  • Author
    Posts
    • #264791
      Participant
      Topics: 3
      Replies: 4
      Points: 29
      Rank: Member

      Hi All,

      Hoping to get some guidance with this. The script works fine, but I would like to know if there is anyway to output before and after changes.

      • This topic was modified 1 month, 1 week ago by kvprasoon. Reason: Code formatting: Please see https://powershell.org/forums/topic/guide-to-posting-code-2/
    • #264848
      Senior Moderator
      Topics: 9
      Replies: 1422
      Points: 5,289
      Helping Hand
      Rank: Community MVP

      you have to log things before and after changes.

      Write to a file or print in console before using Set-AdUser and use -PassThru parameter of Set-AdUser and capture the output in a variable, then print or write to a file using the output variable.

    • #265097
      Participant
      Topics: 3
      Replies: 4
      Points: 29
      Rank: Member

      -PassThru

      Hi kvprasoon,

      My POSH skills don’t go that far unfortunately, could you give me a hint of where I would pace this in the script?

    • #265112
      Senior Moderator
      Topics: 9
      Replies: 1422
      Points: 5,289
      Helping Hand
      Rank: Community MVP

      Like this

      • This reply was modified 1 month, 1 week ago by kvprasoon. Reason: code formatting
    • #265172
      Participant
      Topics: 3
      Replies: 4
      Points: 29
      Rank: Member

      Thank you so much, this worked brilliantly for me.

      Thank you, thank you, thank you.. a million time, so much appreciated

       

       

Viewing 4 reply threads
  • You must be logged in to reply to this topic.