ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   e-mailing a file from vba (https://www.excelbanter.com/excel-programming/279083-e-mailing-file-vba.html)

Paula Osheroff

e-mailing a file from vba
 
I would like to have an excel file e-mailed to me after it
is saved by the user. I know how to set up
for "aftersave", but I'm not sure how to set up the
parameters for the e-mail part of it. Apparently you
can't record a macro for that function, so I need to know
how to set it in VBA. Any help would be appreciated.


John Wilson

e-mailing a file from vba
 
Paula,

The following should work:

ThisWorkbook.Save
ThisWorkbook.SendMail ")

For a lot more information, coding and examples, please see
Ron de Bruin's site:

http://www.rondebruin.nl/sendmail.htm

John

Paula Osheroff wrote:

I would like to have an excel file e-mailed to me after it
is saved by the user. I know how to set up
for "aftersave", but I'm not sure how to set up the
parameters for the e-mail part of it. Apparently you
can't record a macro for that function, so I need to know
how to set it in VBA. Any help would be appreciated.




All times are GMT +1. The time now is 11:58 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com