But what if you fancy starting a new message from a command prompt, possibly without the main window of Outlook Express showing, or if you want to create messages in Windows Mail or Outlook Express programmatically from other applications?
Both can be accomplished with command line arguments. You can create a simple message, but you can also specify default recipients as well as a default subject and message text.
Create a Message in Windows Mail or Outlook Express from the Command Line
To create a new email message in Windows Mail or Outlook Express from the Windows command line:
- For Windows Mail:
- Type '"C:\Program Files\Windows Mail\WinMail" /mailurl:%'.
- For Outlook Express:
- Type '"C:\Program Files\Outlook Express\msimn" /mailurl:%'.
- Make sure you do include the inner (double) but leave out the outer (single) quotation marks.
- Hit Enter.
To create a message with default To:, Cc:, Bcc:, Subject and message body fields:
- Type '"C:\Program Files\Windows Mail\WinMail" /mailurl:%' (Windows Mail) or '"C:\Program Files\Outlook Express\msimn" /mailurl:' (Outlook Express).
- Use the mailto URL encoder to construct a mailto: URL containing the desired default values.
- For a message sent To: "recipient@example.com" by default with a Subject: of "Hello" and a body of "Hi there", the URL would be "mailto:recipient@example.com?subject=Hello&body=Hi%20there", for example.
- Copy and paste the URL to the command line, appending it immediately after "mailurl:".
- Enter a quotation mark '"' between "mailto:" and the email address of the default recipient.
- The full command line using the above example is '"C:\Program Files\Outlook Express\msimn" /mailurl:mailto:"recipient@example.com?subject=Hello&body=Hi%20there' (again including the inner but not including the outermost quotation marks).
Note that you cannot attach files from the command line or have the message delivered automatically. For that, you can try a tool such as Blat, however.

