Results 1 to 3 of 3
  1. #1
    New Lounger
    Join Date
    Oct 2016
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    POWERSHELL Script

    Hi all,

    I am new to powershell and I am stuck for code which should process the following:

    If time is 5:00 PM
    {
    send Email
    }

    I am sorry, but, I just can not do that.

  2. #2
    Administrator
    Join Date
    Mar 2001
    Location
    St Louis, Missouri, USA
    Posts
    23,585
    Thanks
    5
    Thanked 1,059 Times in 928 Posts
    Joe

  3. #3
    5 Star Lounger
    Join Date
    Jan 2010
    Location
    Los Angeles, CA
    Posts
    828
    Thanks
    4
    Thanked 38 Times in 34 Posts
    Don't quite understand what you are attempting to do. Are you wanting:
    a) the script to wait until 5PM and then send an email?
    b) if the script is running, and it is 5PM, send an email
    c) run the script at 5PM; the script send an email (this is best handled via the Windows scheduler)
    My guess is (a), but each one requires slightly different coding, which makes it difficult to answer (and I'm too lazy to provide you with all three answers...)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •