Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: how to send an email via Stata Command

From   <>
To   <>
Subject   st: how to send an email via Stata Command
Date   Mon, 28 Jan 2013 09:17:11 +0100

I use the following command with Win XP and MS Office 2007:

winexec "C:\Programme\Microsoft Office\Office12\OUTLOOK.EXE"  /a "d:\temp.txt" /c ipm.note.whatevername  

I'm not sure if it works with Outlook Express.

Adjust the path to your Outlook Express .EXE.
/a specifies the path to your attachment.
/c specifies that an pre-specified email is send 

To specifiy "ipm.note.whatevername" in Outlook 2007 you open an empty mail and write it. Then save it using "Extras" -> "Forms" -> "Publish Form"
( I don't use the English version so I don't know the correct english menu titles.)

(Or you could use " /m " to only provide address and subject)

This creates and shows the mail but doesn't send it. That's alright with me because I want to check every mail before sending. 
In Outlook you can specify automatic sending for your "ipm.note.whatevername" form.
Difficult to explain for me here. You have to open the form in the form editor and add an "item.send" to the "Item_open" function.
You'll find detailed howtos on the web.

Best wishes

Stefan Gawrich

*   For searches and help try:

© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index