windows下命令列發送郵件blat.exe

來源:互聯網
上載者:User

   windows下命令列發送郵件blat.exe簡介

  下載最新的工具包,解壓並拷貝到作業系統盤的System32 目錄下。我的環境C:WindowsSystem32.

  確認檔案已經拷貝過去:

  blat.dll

  blat.exe

  blat.lib

  批命令例子:

  ----------------- 例子開始 -----------------------------------------

  @echo off

  :::::::::::::: 參數設定::::::::::::::

  set from=xxx@163.com

  set user=xxx

  set pass=xxx

  set to=xxx@163.com

  set subj=測試

  set mail=mail_body.txt

  set server=smtp.163.com

  set attach=attach.rar

  set debug=-debug -log blat.log -timestamp

  ::::::::::::::::: 運行blat :::::::::::::::::

  rem blat %mail% -to %to% -base64 -charset Gb2312 -subject %subj% -server %server% -f %from% -u %user% -pw %pass% -attach %attach% %debug%

  ----------------- 例子結束 -----------------------------------------

  經過測試,中文內容沒有問題(注意源檔案的編碼),支援 163 之類的系統,

  mail_body.txt : 本文

  attach.rar : 附件

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.