Hate

I can not do anything.

You know,

I hate English,

I hate course and classes,

I hate Sheakspare

I hate myself

Believe me baby ,

Even I hate to hate.

Share

How to send email on Windows PowerShell

We can send email to another email account on PowerShell.Let’s see this example:

$smtpServer = "smtp.gmail.com"
$smtpUser = "emailaddress@gmail.com"
$smtpPass = "password"
$mail = New-Object System.Net.Mail.MailMessage
$mail.From = New-Object System.Net.Mail.MailAddress($smtpUser)
$mail.To.Add("sendtoemail@hotmail.com")
$mail.Subject = "Hi"
$mail.Body = "Hello World!"
$smtp = New-Object System.Net.Mail.SmtpClient -argumentList $smtpServer
$smtp.Credentials = New-Object System.Net.NetworkCredential -argumentList $smtpUser,$smtpPass
$smtp.Send($mail)
Share

Hello world!

Welcome to WordPress. This is your first post. Edit or delete it, then start blogging!

Share