ML
    • Recent
    • Categories
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    Powershell: Use PS to email results

    IT Discussion
    ps powershell o365 sendmail
    9
    14
    1.6k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • ObsolesceO
      Obsolesce @NerdyDad
      last edited by

      @nerdydad said in Powershell: Use PS to email results:

      Hope that helps.

      Really? I thought your reply was meant not to help.

      1 Reply Last reply Reply Quote 1
      • NerdyDadN
        NerdyDad
        last edited by

        @gjacobse

        https://mangolassi.it/topic/13325/creating-a-new-user-with-o365-with-powershell

        gjacobseG 1 Reply Last reply Reply Quote 1
        • gjacobseG
          gjacobse @NerdyDad
          last edited by

          @nerdydad said in Powershell: Use PS to email results:

          @gjacobse

          https://mangolassi.it/topic/13325/creating-a-new-user-with-o365-with-powershell

          Thanks - I'll have to see about working through that and seeing what I can merge into the script I have.

          1 Reply Last reply Reply Quote 1
          • JaredBuschJ
            JaredBusch
            last edited by JaredBusch

            I use a PS script I found on 🌶 to email users when passwords are expiring.

            I would link to it but not allowed.

            Minion QueenM coliverC NerdyDadN 3 Replies Last reply Reply Quote 1
            • Minion QueenM
              Minion Queen Banned @JaredBusch
              last edited by Minion Queen

              @jaredbusch said in Powershell: Use PS to email results:

              I use a PS script I found on 🌶 to email users when passwords are expiring.

              I would link to it but not allowed.

              Sorry that this is such a PITA!! But not my doing.

              1 Reply Last reply Reply Quote 0
              • coliverC
                coliver @JaredBusch
                last edited by coliver

                @jaredbusch said in Powershell: Use PS to email results:

                I use a PS script I found on 🌶 to email users when passwords are expiring.

                I would link to it but not allowed.

                I have one from somewhere else let me see if I can find it. Here it is: https://www.serveradventures.com/the-adventures/send-pwdnotification-powershell-script-to-notify-users-of-password-expiration

                1 Reply Last reply Reply Quote 1
                • NerdyDadN
                  NerdyDad @JaredBusch
                  last edited by NerdyDad

                  @jaredbusch said in Powershell: Use PS to email results:

                  I use a PS script I found on 🌶 to email users when passwords are expiring.

                  I would link to it but not allowed.

                  Why don't you just copy and paste the script over here?

                  Its your knowledge. Who's to say that YOU can't share it in both places?

                  Sorry. Saw that important word there "found". I rest my case.

                  ObsolesceO 1 Reply Last reply Reply Quote 0
                  • ObsolesceO
                    Obsolesce @NerdyDad
                    last edited by

                    @nerdydad said in Powershell: Use PS to email results:

                    @jaredbusch said in Powershell: Use PS to email results:

                    I use a PS script I found on 🌶 to email users when passwords are expiring.

                    I would link to it but not allowed.

                    Why don't you just copy and paste the script over here?

                    Its your knowledge. Who's to say that YOU can't share it in both places?

                    Sorry. Saw that important word there "found". I rest my case.

                    I find a lot of 🌶 stuff on pastebin.com. No issues with sharing pastebin stuff on ML.

                    scottalanmillerS 1 Reply Last reply Reply Quote 0
                    • scottalanmillerS
                      scottalanmiller @Obsolesce
                      last edited by

                      @tim_g said in Powershell: Use PS to email results:

                      @nerdydad said in Powershell: Use PS to email results:

                      @jaredbusch said in Powershell: Use PS to email results:

                      I use a PS script I found on 🌶 to email users when passwords are expiring.

                      I would link to it but not allowed.

                      Why don't you just copy and paste the script over here?

                      Its your knowledge. Who's to say that YOU can't share it in both places?

                      Sorry. Saw that important word there "found". I rest my case.

                      I find a lot of 🌶 stuff on pastebin.com. No issues with sharing pastebin stuff on ML.

                      Interesting.

                      1 Reply Last reply Reply Quote 0
                      • nadnerBN
                        nadnerB
                        last edited by

                        I can't remember where is nabbed it from, but I use the following:

                        Function Mailer
                            {
                             $emailTo = ""
                             $emailFrom = "" 
                             $subject="It's broken, damn it" 
                             $smtpserver="" 
                             $smtp=new-object System.Net.Mail.SmtpClient($smtpServer)
                             $Message = @" 
                                                         
                            Insert a useful/meaningful message here. 
                        "@ 
                            
                            }
                        
                        
                             
                        Mailer
                        

                        Last line calls the function (duh for you, but a visitor here might not know).

                        1 Reply Last reply Reply Quote 0
                        • 1 / 1
                        • First post
                          Last post