General discussion

Locked

Excel Tip - USE VBA TO E-MAIL YOUR WORKB

By rvs ·
This is an excellent Tip that you passed on to your readers. I have been
using this strategy and it works well.

My question, any way to place text in the body of the email, in addition to
the subject text?


USE VBA TO E-MAIL YOUR WORKBOOKIt's very easy to send a workbook using Excel VBA code. The workbook is
sent using your default mail program. Simply use the SendMail method as
shown in the sample procedure below.

Sub SendTheWorkbook()
ActiveWorkbook.SendMail _
Recipients:="you@youraddress.com", _
Subject:="Here is the workbook--", _
ReturnReceipt:=False
End Sub

Thanks,
Rick

This conversation is currently closed to new comments.

3 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Comments

Collapse -

Excel Tip - USE VBA TO E-MAIL YOUR WORKB

by DKlippert In reply to Excel Tip - USE VBA TO E- ...

I wish Excel had the ability to send a message, but I don't think it does.

The Excel VBA function is:
SendMail(Recipients, Subject, ReturnReceipt).

You can, howver, do it in Access with a similar function:
DoCmd.SendObject [objecttype][, objectname][, outputformat][, to][, cc][, bcc][, subject][, messagetext][, editmessage][, templatefile].

Collapse -

Excel Tip - USE VBA TO E-MAIL YOUR WORKB

by rvs In reply to Excel Tip - USE VBA TO E- ...

Appreciate the info on access. Unfortunately, almost all my work is with excel.

Thanks

Collapse -

Excel Tip - USE VBA TO E-MAIL YOUR WORKB

by rvs In reply to Excel Tip - USE VBA TO E- ...

This question was closed by the author

Back to Windows Forum
3 total posts (Page 1 of 1)  

Related Discussions

Related Forums