alanlam123
asked on
How to run powershell script to automate
Hi expert
How to write a powershell script to automate the process for getting a file from the C drive from the server show in the followng path "C:\Program Files (x86)\CCTE\OutstandingBala nce " and email to users.
Thanks
Alan lam
How to write a powershell script to automate the process for getting a file from the C drive from the server show in the followng path "C:\Program Files (x86)\CCTE\OutstandingBala
Thanks
Alan lam
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Hi
I am encountered the followng issue;
$cred = New-Object pscredential -ArgumentList @("alan.lam@zuji.com", "La@88898" | ConvertTo-SecureString -AsPlainText -Force)
Send-MailMessage -From alan.lam@zuji.com -To toAddress@lamsoonwin@gmail .com -Attachments @("M:\SIN\RprtZuji\Fri 12_22_2017\files.xls") -Subject "Mail Subject" -SmtpServer "mail.webjet.com.au" -Credential $cred
Capture-for-powershell-errros.PNG
I am encountered the followng issue;
$cred = New-Object pscredential -ArgumentList @("alan.lam@zuji.com", "La@88898" | ConvertTo-SecureString -AsPlainText -Force)
Send-MailMessage -From alan.lam@zuji.com -To toAddress@lamsoonwin@gmail
Capture-for-powershell-errros.PNG
ASKER