Différences
Ci-dessous, les différences entre deux révisions de la page.
| Prochaine révision | Révision précédente | ||
| powershell_mail [2019/11/22 11:17] – créée nekan | powershell_mail [2021/03/05 16:02] (Version actuelle) – nekan | ||
|---|---|---|---|
| Ligne 1: | Ligne 1: | ||
| ====== Envoi de mail ====== | ====== Envoi de mail ====== | ||
| + | <label type=" | ||
| L' | L' | ||
| Ligne 5: | Ligne 6: | ||
| * Référence : [[https:// | * Référence : [[https:// | ||
| - | <code:ps1># On prépare d' | + | <sxh powershell># On prépare d' |
| # L' | # L' | ||
| $From = " | $From = " | ||
| Ligne 49: | Ligne 50: | ||
| # Finalement, on ajoute tous nos arguments à la cmdlet | # Finalement, on ajoute tous nos arguments à la cmdlet | ||
| Send-MailMessage -From $From -To $To -Subject $Subject -Body $Body -BodyAsHtml -SmtpServer $SMTP -Port $Port -UseSsl -Credential $Credential -Attachments $Attachment -Encoding $Encoding | Send-MailMessage -From $From -To $To -Subject $Subject -Body $Body -BodyAsHtml -SmtpServer $SMTP -Port $Port -UseSsl -Credential $Credential -Attachments $Attachment -Encoding $Encoding | ||
| - | </code> | + | </sxh> |
| - | + | ||
| - | --- // | + | |
| ~~DISCUSSION~~ | ~~DISCUSSION~~ | ||