PDA

View Full Version : Auto Print Outlook Attachements as and when a new mail arrives



upendra_agni
03-19-2009, 03:36 AM
Hi,

Can somebody help how to auto print the attachments in Outlook as and when new mail arrives into inbox without any manual intervention and with the help of VBA.

Note: the attachment may be any filetype.

Your quick help is much appreciated.

Regards,
Upendra

JP2112
03-19-2009, 07:46 AM
For the event code portion of your code, see Save Incoming Attachments (http://www.codeforexcelandoutlook.com/blog/2008/05/save-incoming-attachments-choose-your/) for sample code. What you'll want to do is create an ItemAdd event for your Inbox, then when an email comes in, loop through the Attachments collection and save them.

For your printing, see Automatically save and print attachments (http://www.vbaexpress.com/kb/getarticle.php?kb_id=522) for more sample code.

HTH

ps- I know it's none of my business, but I feel obligated to tell you that it what you want to do sounds extremely wasteful.



Hi,

Can somebody help how to auto print the attachments in Outlook as and when new mail arrives into inbox without any manual intervention and with the help of VBA.

Note: the attachment may be any filetype.

Your quick help is much appreciated.

Regards,
Upendra