SAMPLE: Cdoasp.exe Creates Simple Mail Client Using CDO and ASP (244587)



The information in this article applies to:

  • Collaboration Data Objects (CDO) 1.21

This article was previously published under Q244587

SUMMARY

Cdoasp.exe is a collection of Active Server Pages (ASP) pages that uses CDO to access a mailbox on a Microsoft Exchange Server and provide these basic mailing functions:
  • Browsing through the Microsoft Exchange folders for that mailbox (using a treeview control)
  • Opening mail
  • Sending mail
  • Replying to mail
  • Forwarding mail
  • Deleting mail
  • Finding information in the address book

MORE INFORMATION

The following file is available for download from the Microsoft Download Center:
For additional information about how to download Microsoft Support files, click the following article number to view the article in the Microsoft Knowledge Base:

119591 How to Obtain Microsoft Support Files from Online Services

Microsoft scanned this file for viruses. Microsoft used the most current virus-detection software that was available on the date that the file was posted. The file is stored on security-enhanced servers that help to prevent any unauthorized changes to the file.

FilenameSizePurpose
Mainpage.asp1KBDefault page that loads the two vertical frames.
LftFrame.asp6KBHolds the main treeview control and the log on text.
ListMail.asp7KBContains a list box to hold messages.
NewMail.asp3KBHolds the template for a new mail message.
Open.asp2KBHolds the template for opening an old message.
Reply.asp5KBHolds the template for the reply to a message.
Forward.asp5KBHolds the template for forwarding a message.
Addbook.asp3KBDisplays a combo box listing all the address lists available.
Blank.asp1KBUsed as the startup page when the main page is loaded in the beginning.
Readme.txt4KBGives descriptions about what each page does.


This sample assumes:

  • You have all the permissions set on your Internet Information Server (IIS) server so that you can access Exchange from the IIS server. More information on exchange permissions and security can be found in the following MSDN article:
  • You have the treeview control (Mscomctl.ocx) registered.

Steps to use this sample:

  1. Extract the Cdoasp.exe file in a folder under your wwwroot\.. folder.
  2. Set the security for the folder to Windows NT Challenge/Response.
  3. Load the file Mainpage.asp in your browser by typing the full path, which will be http:\\IISservername\<foldername>\Mainpage.asp.
  4. Enter your Exchange server name and mailbox alias in the left frame and click logon. A treeview control will appear showing all of your folders except Tasks, Totes, Journal, and Contacts. You will also see New Mail and Address Book links.
  5. Expand the treeview control, and when you click on your folder, you will see the messages in a list box on the right.
  6. To use the address book, click Address Book to look up information in your address book.
  7. Click New Mail to bring up a form to fill out and send mail.

Modification Type:MinorLast Reviewed:8/5/2004
Keywords:kbdownload kbgraphxlinkcritical kbMsg KB244587 kbAudDeveloper