Click here to Skip to main content
65,938 articles
CodeProject is changing. Read more.
Articles
(untagged)

Send Mails in VB with Multiple Attachments using DOS Command Line

0.00/5 (No votes)
13 Sep 2007 1  
Send email using DOS command line, the application will read itself txt file and add into email body. Added the size limit of attachments.

Introduction

Messaging Application Programming Interface (MAPI) is a messaging architecture and a Component Object Model based API for Microsoft Windows. MAPI allows client programs to become (electronic mail) messaging-enabled, -aware, or -based by calling MAPI subsystem routines that interface with certain messaging systems and message stores. MAPI refers both to the application programming interface as well as the proprietary protocol which Microsoft Outlook uses to communicate with Microsoft Exchange.

As well as the Extended MAPI client interface, programming calls can be made indirectly through the API client interface Simple MAPI, or through the Common Messaging Calls (CMC) API client interface, or by the object-based CDO Library interface. These three methods are easier to use and designed for less complex messaging-enabled and -aware applications. The full Extended MAPI interface is required for messaging-based applications.

MAPI was originally designed by Microsoft. The company founded its Microsoft Mail team in 1987, but it was not until it acquired Consumers Software Inc in 1991 to obtain Network Courier that it had a messaging product. Reworked, it was sold as Microsoft PC Mail (or Microsoft Mail for PC Networking). The basic API to Microsoft PC Mail was MAPI version 0. MAPI uses functions based on the X.400 XAPIA standard.

Extended MAPI is the main e-mail data access method used by Microsoft Exchange. Simple MAPI and CMC were removed from Exchange 2003.

Background

  • You can send mails using DOS command line parameter.
  • You can send multiple attachments using this sample app.
  • You can check the size of attachments.
  • The run sample command line parameter is "Mapimail.exe FolderName|FileName|status"

Points of Interest

  1. I would like to say that the mapi mail method is very easy and fast to send mails.
  2. There is no extra installation required in other PCs to run this.

History

  • 13th September, 2007: Initial post

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here