OL98: Command Line for Creating a Pre-addressed E-mail MessageID: Q181991
|
This article describes how to use command line switches to create a new
e-mail message that is pre-addressed (with the To field filled in
automatically). You can do this in the following ways:
Microsoft provides programming examples for illustration only, without warranty either expressed or implied, including, but not limited to, the implied warranties of merchantability and/or fitness for a particular purpose. This article assumes that you are familiar with the programming language being demonstrated and the tools used to create and debug procedures. Microsoft support professionals can help explain the functionality of a particular procedure, but they will not modify these examples to provide added functionality or construct procedures to meet your specific needs. If you have limited programming experience, you may want to contact the Microsoft fee-based consulting line at (800) 936-5200. For more information about the support options available from Microsoft, please see the following page on the World Wide Web:
http://www.microsoft.com/support/supportnet/refguide/
"C:\Program Files\Microsoft Office\Office\Outlook.exe" /c ipm.note /m <full e-mail name>where <full e-mail name> is the complete e-mail address of the recipient such as JohnDoe@msn.com.
/ c ipm.note /m <full e-mail name>where <full e-mail name> is the complete e-mail address of the recipient such as JohnDoe@msn.com.
Shell "C:\Program Files\Microsoft Office\Office\Outlook.exe /c ipm.note /m <full e-mail name>"where <full e-mail name> is the complete e-mail address of the recipient such as JohnDoe@msn.com.
mailto:<to email>?cc=<cc email>&bcc=<bcc mail>&subject=<subject
text>&body=<body text>
Where the following variable definitions apply:
Variable Field Entry
--------------------------------------------------------------
<to e-mail> e-mail address to appear in the To field
<cc mail> e-mail address to appear in the CC field
<bcc mail> e-mail address to appear in the BCC field
<subject> text to appear in the Subject field
<body text> text to appear in the Body of the message
Note the position of the question mark and ampersand characters in the
command line syntax.
Space ( ) %20
Comma (,) %2C
Question Mark (?) %3F
Period (.) %2E
Exclamation Point (!) %21
Colon (:) %3A
Semicolon (;) %3B
An example of a command line for the Subject and Body text using these
variables would be:
&subject=Hello%20World%21&body=How%20are%20you%2C%20John%3F
This command line would yield:
Subject: Hello World!
Body : How are you, John?
For more information about automating Outlook, please see the following articles in the Microsoft Knowledge Base:
Q181202 OL98: How to Automate Outlook from Another ProgramFor more information about Outlook command line switches, please see the following article in the Microsoft Knowledge Base:
Q182396 OL98: How to Set a Form's From Field Using VBScript
Q182349 OL98: Questions About Custom Forms and Outlook Solutions
Q182112 OL98: Additional Command-Line SwitchesOr, click the Office Assistant, type "control starting Outlook," click Search, and then click to view "Control what happens when you start Outlook."
Q120802 Office: How to Add/Remove a Single Office Program or Component
Additional query words: parameter parameters argument arguments
Keywords : kbcode kbdta
Version : WINDOWS:
Platform : WINDOWS
Issue type : kbhowto
Last Reviewed: July 29, 1999