Send-Mailmessage Query

Hi All
Am trying to send an email with attachment in body (HTML format ) which is coming fine without any issue
but i need to add few test message in body, ...like .. HI All please see the below report or something
The attachment is the output of the one scripts stores in local drive (d:\output) as HTML file
Vatriable $html is outputfile which is showing in the body
    $notificationto = "[email protected]
    $cc = "[email protected]"
    $notificationfrom = "[email protected]"
    $smtpserver = "smtp.labbites.coml"
Send-MailMessage -Body "$Html"-bodyashtml -to $notificationto -CC $CC -from $notificationfrom -Subject "Report from App notes" -SmtpServer $smtpServer 
How do i add additional test messgae in the body along with the HTML report

Hi,
For this issue, actually, we have a dedicated support team regarding Script. I recommend you ask your question on the Script forum which is staffed by more experts specializing in this kind of problems to get better help.
http://social.technet.microsoft.com/Forums/scriptcenter/en-US/home?category=scripting
Thanks for kindest understanding.
Best regards,
Belinda
Belinda Ma
TechNet Community Support

Similar Messages

  • Central Management server - executed a query but how to send the query output in the form of mail?

    Hi All,
    i have used CMS in SQL 2008 R2. i have added couple of servers in its group. i have executed a query & i need to send the query output in the form of email.
    basically query is checking the rows count from couple of user tables in servers.
    issue here is how to copy the data that is used by CMS? i need to work on automate the rows count in difft user table in db servers
    could you please suggest how can i achieve this?

    Copy to what?
    SELECT COUNT(*) FROM sys.objects
    Running the above statement returns two columns (server name and count)
    All the servers SS2005  and onwards , then use
    EXEC msdb.dbo.sp_send_dbmail 
         @profile_name = 'name', 
         @recipients = '[email protected]', 
         @query = 'SELECT COUNT(*) FROM sys.objects', 
         @subject = 'Count rows'
    Best Regards,Uri Dimant SQL Server MVP,
    http://sqlblog.com/blogs/uri_dimant/
    MS SQL optimization: MS SQL Development and Optimization
    MS SQL Consulting:
    Large scale of database and data cleansing
    Remote DBA Services:
    Improves MS SQL Database Performance
    SQL Server Integration Services:
    Business Intelligence

  • How to send a message with Send-MailMessage cmdLet powershell exchange which uses a html file as a parameter

    Before the mailboxes migration E2003 toward E2010 SP2, I have to send a mail which body already exists as a html file.
    Here the powershell I currently use :
    import-csv d:\path\TestLot.csv  | foreach {Send-MailMessage -To $_.PrimarySmtpAddress -From
    [email protected] -Subject "Migration " -body "Your mailbox Migration will start in 2 days." -SmtpServer servXXX}
    And it is allright !
    But, I was asked to use an existing html file instead of my poor : -body "Your mailbox Migration will start in 2 days." 
    Does anybody know the way to do this ?
    Thank you for your help
    PATMOY
    BOAT

    Hi,
    I have the html code in a variable so i can personalize the mails:
    $htmlcode = '<html><body style="background:#FFFFFF"><head><title>Activaion email</title></head>'
    $htmlcode += '<style type="text/css">'
    $htmlcode += '#HLine { font-size:20px; font-family:Verdana; font-weight: bold; }'
    $htmlcode += '#txt { font-size:12px; font-family:Verdana;}'
    $htmlcode += '</style>'
    $htmlcode += '<img src="/img/HBPMAN0aGcc.gif" width="52" height="52" />&nbsp;&nbsp;&nbsp;<br />'
    $htmlcode += '<h1 id="HLine">Your BlackBerry account has been created ...</h1>'
    $htmlcode += '<div id="txt"><strong>... Your User Data:</strong><br />'
    $htmlcode += '&nbsp;&nbsp;&nbsp;<br /><table border="0" id="txt"><tr><td>&nbsp;&nbsp;<strong>Username:</strong></td><td>'+$UsrData.Email+'</td></tr>'
    $htmlcode += '<tr><td>&nbsp;&nbsp;<strong>Activation Password:</strong></td><td>'+$UsrData.pass+'</td></tr></table><br />'
    $htmlcode += '<strong>The activation credentials are valid for just 5 days after receipt of this email!</strong><br /><br/ >'
    $htmlcode += '<strong>... Next Steps: </strong><br /><br />'
    $htmlcode += '<a href= "/bb/doc/EN.pdf">- Activate your Device</a>&nbsp;<br />'
    $htmlcode += '&nbsp;&nbsp;To be able to use your new BlackBerry you need to complete this steps.<br /><br />'
    $htmlcode += '<a href= "/bb/doc/Tips.pdf">- Tips and Tricks for your Device</a><br />'
    $htmlcode += '&nbsp;&nbsp;Tips and Tricks to make your Device experience a success.<br /><br />'
    $htmlcode += '<strong>... in case you require technical support:</strong><br /><br />'
    $htmlcode += 'If you experiance problems with your Device, please contact your local IT-Support.<br /><br />'
    $htmlcode += 'Thank You.'
    $htmlcode += '<br/><div></body></html>'
    Send-MailMessage -to $UsrData.Email -From $from -Body $htmlcode -SmtpServer $smtp -Subject $subject -BodyAsHtml
    If you want to make sure the mail is displayed as a HTML Mail add to the send-mailmessage the option
    -BodyAsHtml
    Regards
    Dan

  • Can any one send select query for this?

    Hi,
    can any one plese send select query for the following query.please send as early as possible.
    Loop through the I_BSID internal table to fill records in I_OUTPUT.Combine data from I_BSID, I_KNKK, I_KNKK_KNKLI, I_KNA1 and I_KNVV into I_OUTPUT based on the linking conditions .Field Description Source are
    I_OUTPUT-BUKRS     Company code     I_BSID-BUKRS
    I_OUTPUT-KUNNR     Customer number     I_BSID-KUNNR
    I_OUTPUT-NAME1     Customer Name     I_KNA1-NAME1
    I_OUTPUT-KNKLI     Credit account     I_KNKK-KNKLI
    I_OUTPUT-KDGRP     Customer Group     I_KNKK-KDGRP
    I_OUTPUT-KLIMK     Credit Limit     I_KNKK_KNKLI-KLIMK
    I_OUTPUT-KVGR1     Business Unit     I_KNVV-KVGR1
    I_OUTPUT-REBZG     Invoice Number     I_BSID-REBZG
    I_OUTPUT-BLDAT     Invoice Date     I_BSID-BLDAT
    I_OUTPUT-WAERS     Document Currency     I_BSID-WAERS
    I_OUTPUT-DUE_DATE     Due Date     Based on below
    Calculation
      Get the Payment terms days combining I_BSID and I_T052 based on the linking conditions mentioned above.    Note : a) Baseline Date : If baseline date I_BSID-ZFBDT is blank , use the Document Date.b) Payment Term Days :If I_BSID-ZBD3T is not blank, take this as Payment Term Days for Due date calculation.
                       If I_BSID-ZBD3T is Blank, then get payment term days from I_T052 based on I_BSID-ZTERM. If there are more than one record in I_T052 for the given Payment term, get the day part from baseline date and select the first record where the day limit I_T052-ZTAGG is greater than the day part.If I_BSID-ZBD3T is blank and I_BSID-ZTERM is also blank, then take Y000 (Due Immediately) as Payment term and proceed with the above logic. Set the payment term field blank while printing.
    Calculate Due date : For Debits, Determine Due Date = Baseline Date + Payment term Days(not discount days)                                                          For  Credits  Due date = Baseline date.Then, move the amount I_BSID-DMBTR to respective buckets (Not yet Due, Current Due, Past due 1-30, Past Due 31-60 etc.)  Based on the due date.
    Thanks&Regards,
    praveen kumar.A

    HI,
    To get Open Items you can use Function module:
    data:i_items TYPE STANDARD TABLE OF rfpos.
    CALL FUNCTION 'CUSTOMER_OPEN_ITEMS'
    EXPORTING
    bukrs = p_bukrs
    kunnr = wa_customer-kunnr
    TABLES
    t_postab = i_items
    EXCEPTIONS
    no_open_items = 1
    OTHERS = 2.
    Table I_items will have all the open items for that Customer in the given company code.
    Well for Clear Items: Try
    GET_CLEARED_ITEMS or FMITPOFM_CLEARED_ITEMS_GET.
    Hope it helps.
    Manish

  • Send text file content as the body of an email using Send-MailMessage

    I am taking the last 8 lines of a bunch of robocopy logs and bunching them together.  
    Get-ChildItem -Filter *.log | ForEach {
    $a += Get-Content $_.Name | Select -Last 8
    $a += Write-output ' '`r
    $a += Write-Output '------------------------------------------------------------------------------'`r
    I then wanted to use this as the body of an email (send-mailmessage).  It all works but the formatting is lost in the email. I've tried using Out-String and ConvertTo-HTML with little luck.
    If I look at $a in the above it looks fine in the PowerShell console it's just lost when it reaches my inbox.
    I am using v2 of PowerShell and sadly can't upgrade it.

    The issue isn't that part. It's the content of the log files that loses its formatting.
    $a += Get-Content $_.Name | Select -Last 8

  • How to send digitally sign S/MIME messages with Powershell cmdlet Send-MailMessage?

    Hello,
    using AD Windows PKI I assigned a certificate EKU (1.3.6.1.5.5.7.3.4) to sign emails and get this with
    autoenrollment also to my CERT Store PS
    CERT:\CurrentUser\UserDS\ or the certificate could found via MMC / certificates in the store structur under "Active Directory User Object".
    Signed messages (red icon) to send as S/MIME message using Outlook 2010 is not a problem.
    Using PowerShell cmdlet Send-MailMessage to be sent company notification for a new passwordpolicy some days before pwd expired?! I use the cmdlet already successfully to filling HTML bodies with variables and send to individuals accounts.
    Reduced simplified PS code:
    $SMTPBodyHtmlTemplate = Get-Content "C:\PS\Template\HTMLBody.html" | Out-String
    Function SendEmailNotification # /* SEND E-MAIL Notification to User */#
    [string] $SMTPServer = "mail.domain.local"
    $CurrentUser = "$env:username"
    [string]$SMTPFrom = (Get-ADUser $CurrentUser -properties mail).mail
    [string[]] $SMTPTo = $($Obj.EmailAddress)
    [string]$SMTPSubject = "Notification!"
    [String]$SMTPBodyHtml = $SMTPBodyHtmlTemplate.Replace("UserDisplayname","$($UserDisplayname)")
    Send-MailMessage -From $SMTPFrom -To $SMTPTo -Subject $SMTPSubject -BodyAsHtml $SMTPBodyHtml -dno OnFailure -SmtpServer $SMTPServer -encoding ([System.Text.Encoding]::UTF8) -ErrorAction Continue
    How can I use the PSDrive own CERT and using PowerShell cmdlet Send-MailMessage
    to send a signed message, without development experience?
    Thanks in advance for cooperation.
    Manfred Schüler

    Hi,
    could create with an other colleague a DLL file (with this informations) for successfully sending sign messages from PS-Script. 
    Function SendEmailNotification # /* SEND SIGN E-MAIL */#
    $SMTPBodyHtmlTemplate = Get-Content "C:\PS\Template\HTML.html" | Out-String
    [System.Reflection.Assembly]::LoadFile("C:\PS\Assembly\Cpi.Net.SecureMail.dll") | Out-Null
    [string]$strSmtpServer = "smtp.domain.local"
    [string]$strSmtpPort = "25"
    [string]$strFrom = (Get-ADUser $CurrentUser -properties mail).mail
    [string]$strFromAlias = (Get-ADUser $CurrentUser -properties DisplayName).DisplayName
    [string]$strTo = $UserEmailAddress
    [string]$strToAlias = $UserEmailDisplayName
    [String]$strSubject = "Subject as you like"
    [string]$strBody = $SMTPBodyHtmlTemplate.Replace("UserDisplayname","$($UserDisplayname)")
    $objMail = New-Object Cpi.Net.SecureMail.SecureMailMessage
    $objFrom = New-Object Cpi.Net.SecureMail.SecureMailAddress($strFrom,$strFromAlias,$objCert,$objCert)
    $objTo = New-Object Cpi.Net.SecureMail.SecureMailAddress($strTo,$strToAlias)
    $objMail.From = $objFrom
    $objMail.to.Add($objTo)
    $objMail.Subject = $strSubject
    $objMail.Body = $strBody
    $objMail.IsBodyHtml = $TRUE
    $objMail.IsSigned = $TRUE
    $objMail.IsEncrypted = $FALSE
    $objSMTPClient = New-Object System.Net.Mail.SmtpClient($strSmtpServer,$strSmtpPort)
    $objSMTPClient.Credentials = [System.Net.CredentialCache]::DefaultNetworkCredentials
    $objSMTPClient.send($objMail)
    Maybe Microsoft can implement this in future versions of the cmdlets Send-MailMessage ;-)
    Manfred Schüler

  • Send-MailMessage CommandNotFoundException

    Hi, I have no issues running the Send-MailMessage on the Windows powershell on the server. However on the SQL powershell or through SQL Agent I get this message: The version is 2.0
    SQL powershell :   + FullyQualifiedErrorId : CommandNotFoundException
    SQLAgent shows: The term 'Send-MailMessage' is not recognized as the name of a cmdlet, function, script file, or operable program
    Thank you
    Paula

    I did it on windows powershell as I mentioned there everything works fine.
    On SQL :
    PS SQLSERVER:\SQL\DEFAULT> Add-pssnapin SqlServerProviderSnapin100
    The term 'Add-pssnapin' is not recognized as the name of a cmdlet, function, sc
    ript file, or operable program. Check the spelling of the name, or if a path wa
    s included, verify that the path is correct and try again.
    At line:1 char:13
    + Add-pssnapin <<<<  SqlServerProviderSnapin100
        + CategoryInfo          : ObjectNotFound: (Add-pssnapin:String) [], Comman
       dNotFoundException
        + FullyQualifiedErrorId : CommandNotFoundException
    PS SQLSERVER:\SQL\DEFAULT> Add-pssnapin SqlServerCmdletSnapin100
    The term 'Add-pssnapin' is not recognized as the name of a cmdlet, function, sc
    ript file, or operable program. Check the spelling of the name, or if a path wa
    s included, verify that the path is correct and try again.
    At line:1 char:13
    + Add-pssnapin <<<<  SqlServerCmdletSnapin100
        + CategoryInfo          : ObjectNotFound: (Add-pssnapin:String) [], Comman
       dNotFoundException
        + FullyQualifiedErrorId : CommandNotFoundException
    Paula

  • Does the local server send the query to remote server?

    I have 2 servers,a local server connect with remote server through database link.If I execute a query at local server but only access tables in remote server,does local server send this query to remote server or all the tables at remote server will send to local server?If local server send this query to remote server,does it can execute another query while it waits the result send from remote server?
    Any help would be appreciated
    Regards

    Yes is executed on remote , and the remote can accept queries as normal see my example below
    SQL> select * from v$database@prod_p;
    Execution Plan
    Plan hash value: 3039639316
    | Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time
    | Inst |
    | 0 | SELECT STATEMENT REMOTE| | 100 | 64400 | 0 (0)| 00:00:0
    1 | |
    | 1 | MERGE JOIN CARTESIAN | | 100 | 64400 | 0 (0)| 00:00:0
    1 | |
    |* 2 | FIXED TABLE FULL | X$KCCDI | 1 | 582 | 0 (0)| 00:00:0
    1 | RPRD |
    | 3 | BUFFER SORT | | 100 | 6200 | 0 (0)| 00:00:0
    1 | |
    | 4 | FIXED TABLE FULL | X$KCCDI2 | 100 | 6200 | 0 (0)| 00:00:0
    1 | RPRD |
    Predicate Information (identified by operation id):
    2 - filter("DI"."INST_ID"=USERENV('INSTANCE'))
    Note
    - fully remote statement

  • Send BW query results as HTML email from ABAP program

    I have published a code sample for sending BW query results as HTML email from ABAP program. if you have any questions or clarification, please post them here.
    the same can be accessed from this link.
    http://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/b7658119-0a01-0010-39a9-b600c816f370
    Regards
    Raja
    Message was edited by: Durairaj Athavan Raja

    OK forget about my earlier post.
    do the following changes.
    declare the following variables:
    data: xtext type standard table of solix .
    DATA: atta_sub TYPE sood-objdes .
    after the call of FM SCMS_STRING_TO_FTEXT add the following code.
    CALL FUNCTION 'SO_SOLITAB_TO_SOLIXTAB'
      EXPORTING
        ip_solitab        = text
    IMPORTING
       EP_SOLIXTAB       = xtext .
    and after the following statement
    document = cl_document_bcs=>create_document(
                              i_type    = 'HTM'
                              i_text    = text
                              i_length  = conlengths
                              i_subject = subject ).
    add the following code
    CALL METHOD document->add_attachment
                EXPORTING
                  i_attachment_type    = 'htm'
                  i_attachment_subject = atta_sub
                  i_att_content_hex    = xtext.
    now you will have results both in the body as well as attachment. (this is for test you can remove one of them )
    Regards
    Raja

  • Passing the content of txt file to body of Send-MailMessage

    Hi,
    I am trying to send a report using send-mailmessage cmdlet and I am unable to pass the content of the file as it is to body of the message. It gets converted to a single line string (the escape character aren't getting recognized) or body of the mail has
    system.object[] as output.
    Script1:
    $body = Get-Content -Path C:\TEMP\Body.txt | Out-String
    Send-MailMessage -To <toaddress> -Cc <ccaddress> -From <fromaddress> -Subject "$subject" -Body [string]$body -BodyAsHtml -SmtpServer $server
    Error:
    Body of the mail is seen as [string]<content in a continous line>. The actual body in the txt doc is written as we generally write emails
    Script2:
    $body = Get-Content -Path C:\TEMP\Body.txt
    Send-MailMessage -To <toaddress> -Cc <ccaddress> -From <fromaddress> -Subject "$subject" -Body $body -BodyAsHtml -SmtpServer $server
    Error:
    Send-MailMessage : Cannot convert 'System.Object[]' to the type 'System.String' required by parameter 'Body'. Specified method is not supported.
    At line:1 char:149
    + ... subject" -Body $body -BodyAsHtml -SmtpServer $server
    +                    ~~~~~
        + CategoryInfo          : InvalidArgument: (:) [Send-MailMessage], ParameterBindingException
        + FullyQualifiedErrorId : CannotConvertArgument,Microsoft.PowerShell.Commands.SendMailMessage
    Script3:
    $body = [string]::Join("`r`n",(Get-Content -Path C:\TEMP\Body.txt))
    Send-MailMessage -To <toaddress> -Cc <ccaddress> -From <fromaddress> -Subject "$subject" -Body $body -BodyAsHtml -SmtpServer $server
    Error:
    Send-MailMessage : Cannot convert 'System.Object[]' to the type 'System.String' required by parameter 'Body'. Specified method is not supported.
    At line:1 char:149
    + ... subject" -Body $body -BodyAsHtml -SmtpServer $server
    +                    ~~~~~
        + CategoryInfo          : InvalidArgument: (:) [Send-MailMessage], ParameterBindingException
        + FullyQualifiedErrorId : CannotConvertArgument,Microsoft.PowerShell.Commands.SendMailMessage
    Thanks in Advance,
    Ankush Shah

    removing the -BodyAsHTML I am getting the below error
    Send-MailMessage : Cannot convert 'System.Object[]' to the type 'System.String' required by parameter 'Body'. Specified
    method is not supported.
    At line:1 char:149
    + ... subject" -Body $body -SmtpServer $server
    + ~~~~~
    + CategoryInfo : InvalidArgument: (:) [Send-MailMessage], ParameterBindingException
    + FullyQualifiedErrorId : CannotConvertArgument,Microsoft.PowerShell.Commands.SendMailMessage

  • Error in send-mailmessage command

    Hello,
    I am executing the powershell command  to send mails from internal SMTP Server but when am executing this command getting error as "Unable to connect to the remote server".I have checked no port blocking this ,no anti virus is installed. the
    machine have permission to relay the mail.
    Please help me to resolve the issue.
    Thanks 
    RICHA KM

    Are you using an alternate port for SMTP? Send-MailMessage has a parameter to specify an alternate port to use if that is the case. If you run the following command (replace 'computername' and 'port' with the system you are attempting to connect to)...
    (New-Object Net.Sockets.TCPClient -ArgumentList "Computername","Port").Connected
    ...does it come back as true for the open port?
    Boe Prox
    Blog |
    Twitter
    PoshWSUS |
    PoshPAIG | PoshChat |
    PoshEventUI
    PowerShell Deep Dives Book

  • Send-mailmessage cmdlet not sending mail

    hi
    I am using send-mailmessage cmdlet in one scripts from my domain machine to send one attachment to my user id. I have added my IP on SMTP/Relay server also.
    Send-mailmessage -from "user1 <[email protected]> -to "user2 <[email protected]>" -subject " Test Mail " -attachment " File details "
    -smtp <IP>
    This cmdlet executes without any error but mail is not trigeer to respective user. Telnet to smtp server works from my machime on 25 port.
    OS - Win 7 SP1 ; Powershell Ver - 2.0
    Help me what need to check more.

    Hi,
    As a troubleshooting step, try using BLAT via CMD to make sure that the issue isn't server related:
    http://sourceforge.net/projects/blat/
    Don't retire TechNet! -
    (Don't give up yet - 12,575+ strong and growing)

  • Powershell : Send-MailMessage -Body paramenters is not working with commands like (Get-ExchangeServer) etc

    I am trying to send email from Powershell .
    When i run this:
    Send-MailMessage -From "[email protected]" -To "[email protected]" -Subject "Test email" -Body  "This is Test Email" -SmtpServer "mail01.xxx.xx"
    then i successfully receive email .
    But when i try to use other commands in -Body parameter then it gives error:
    For example:
     Send-MailMessage -From "[email protected]" -To "[email protected]" -Subject "Test email"
    -Body (Get-ExchangeServer) -SmtpServer "mail01.xxx.xx"
    Send-MailMessage : Cannot convert 'System.Object[]' to the type 'System.String'
     required by parameter 'Body'. Specified method is not supported.
    At line:1 char:96At line:1 char:116
    + Send-MailMessage -From "[email protected]" -To "[email protected]" -Subject "Test email" -Body (Get-ExchangeServer <<<< ) -SmtpServer "mail01.xxx.xx"
        + CategoryInfo          : ObjectNotFound: (Get-ExchangeServer:String) [], CommandNotFoundException
        + FullyQualifiedErrorId : CommandNotFoundException
    My requirement is to send email from powershell and send exchange related data in email.

    OK I got it .. The solution is to add Out-String
    Send-MailMessage -From "[email protected]" -To "[email protected]" -Subject "Test email"
    -Body (Get-ExchangeServer | Out-String) -SmtpServer "mail01.xxx.xx"

  • Send-MailMessage and Automatic Email Generation with Exchange 2007

    Good morning everyone,
    Is it possible to create a powershell script to automatically send messages with Send-MailMessage? I've been asked if we can make Exchange/Outlook automatically generate its own emails to send. My answer was no, you generally need a third party tool to do
    this, such as SendLater or have an application that processes emails through Exchange automatically.
    Then we came upon Send-MailMessage and while I can send emails to myself all night and day, I need to know if I can send with this command automatically throughout the day. I'm somewhat still new to powershell scripting and not sure where to begin or if
    this is even possible.
    Thanks for any assistance!

    Hi ExAdmin29,
    Great information from Ed.
    I also find a related blog contains detailed steps, for your reference:
    Creating Scheduled Tasks for Exchange 2010 PowerShell Scripts
    http://www.mikepfeiffer.net/2010/02/creating-scheduled-tasks-for-exchange-2010-powershell-scripts/
    Disclaimer:
    Microsoft is providing this information as a convenience to you. The sites are not controlled by Microsoft. Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. Please make sure
    that you completely understand the risk before retrieving any suggestions from the above link.
    Thanks
    Mavis
    Mavis Huang
    TechNet Community Support

  • Powershell send-mailmessage error - helo command rejected: need fully-qualified

    did you try the From and To email addresses in the format of
    "User01 "
    "User02 "
    Like the examples here?
    https://technet.microsoft.com/en-us/library/hh849925.aspx

    Hello,I need help with sending e-mails via Powershell using SMTP authentication. I've described the problem here on StackOverflow already:
    http://stackoverflow.com/questions/31542444/powershell-send-mailmessage-error-helo-command-rejected-...Re-pasting here: """I've read many sources regarding this issue, but no luck :/I am trying to use Powershell 4.0 (Windows server 2012 R2) to send e-mails via the Send-MailMessage commandlet in this way:PHP$From = "[email protected]"$To = "[email protected]"$Subject = "e-mail odeslany z powershellu :)"$Body = "..."$SMTPServer = "smtp.mydomain.cz"$SMTPPort = "587"$credentials = new-object Management.Automation.PSCredential “[email protected]”, (“xxxpasswordxxx” | ConvertTo-SecureString -AsPlainText -Force)Send-MailMessage -From $From -to $To -Subject $Subject -Body $Body -SmtpServer...
    This topic first appeared in the Spiceworks Community

Maybe you are looking for

  • Vendor's material

    Hi experts, I am creating vendor's stock report. I am facing problem i am not getting all material for perticular vendor in MSEG but when i am checking standard report ME2O or MB5B it showing the material at vendor. so how can i get all material for

  • 3.1 Page 0 LOV APP_ITEM issues

    Hello, I recently upgraded from 3.0.1 to 3.1 and my application appears to have broken. I have a select list on page 0. The LOV query references an application item using the bind syntax. similar to select col1 d, col2 r from my_table where col3 = :M

  • Dreamweaver template declaration affects Google Map loading

    My Dreamweaver Template declaration statement <!-- InstanceBegin template="/Templates/kayaking.dwt" codeOutsideHTMLIsLocked="false" --> is preventing a Google Map from loading.  It works fine in IE and Firefox, but not in Safari and Chrome.  The weir

  • Can't reset password email

    Hi Excuce me Please help me for rest password email for my iPhone 4S Email is xxxxxxxxxxx I forget passwords and security questions. please help me Thank You sir Abdulmohsen Alsabaey K.S.A _ Riyadh <Edited By Host>

  • What causes my screen to blink

    what causes my screen to flash after start up?