Send mail from a Windows script

前端 未结 7 867
耶瑟儿~
耶瑟儿~ 2021-01-02 07:11

I would like to send mail from a script on a Windows Server 2003 Standard Edition. I think the server setup is pretty much out of the box.

The mail server is an Exch

7条回答
  •  被撕碎了的回忆
    2021-01-02 07:47

    If you have outlook/exchange installed you should be able to use CDONTs, just create a mail.vbs file and call it in a batch file like so (amusing they are in the same dir)

    wscript mail.vbs
    

    for the VBScript code check out

    http://support.microsoft.com/kb/197920

    http://www.w3schools.com/asp/asp_send_email.asp

    forget the fact they the two links speak about ASP, it should work fine as a stand alone script with out iis.

提交回复
热议问题