Ask the Community
Groups
How do I send attachments using the SEND EMAIL function? - Connect IT Community | Kaseya
<main> <article class="userContent"> <div>QUESTION</div> <div> <p>How do I send email attachments using scripting? There doesn't appear to be any way of attaching files using the Send Email script command.</p> <p> </p> <p>ANSWER</p> <p>Either:<br><br>a) Use the Execute Shell Command or Execute File command to run a command line email utility such as blat.exe (<a rel="nofollow" href="/home/leaving?allowTrusted=1&target=http%3A%2F%2Fwww.blat.net%2F">http://www.blat.net/</a>) to send the email. If you want to do this from the Kaseya server, you'll need to use the Get File command to copy the file up to the Kaseya server first.<br><br>or<br><br>b) Use the Get Variable > File Contents command to get the contents of a text file, and then insert this into the body of the Send Email command using the #variable#.</p> <p><br>See <a rel="nofollow" href="/home/leaving?allowTrusted=1&target=http%3A%2F%2Fkb.kaseya.com%2Farticle.aspx%3Fp%3D11855%26article%3D296884">http://kb.kaseya.com/article.aspx?p=11855&article=296884</a> for an issue and workaround for inserting Unicode text files into the body of the email.</p> <p> </p> <p>APPLIES TO</p> <p>Scripting tab<br>Email<br>SMTP<br>NNTP<br>MAPI</p> </div> </article> </main>