How To Debug a MAPI Transport Provider (200026)



The information in this article applies to:

  • Microsoft Extended Messaging Application Programming Interface (MAPI)
  • Microsoft Visual C++, 32-bit Professional Edition 5.0
  • Microsoft Visual C++, 32-bit Professional Edition 6.0
  • Microsoft Visual Basic Enterprise Edition for Windows 5.0
  • Microsoft Visual Basic Enterprise Edition for Windows 6.0

This article was previously published under Q200026

SUMMARY

It is often necessary to debug your transport provider during the development process. This article describes how to debug a MAPI Transport provider.

MORE INFORMATION

The following are the necessary steps to take when debugging a MAPI transport:
  1. Start an instance of Microsoft Visual C++ program with no project or workspace loaded.
  2. Start Microsoft Outlook.
  3. In Microsoft Visual C++, select the Build menu. Click Start and choose "Attach to Process..."
  4. Select MAPISP32.exe from the list of processes and click OK.
  5. From the File menu, select the File and choose "Open..." to load a source code file from your project in which you want to set a breakpoint.
You can also use WinDbg that comes with Windows NT Resource kit to debug MAPI Transport Provider. The following are the steps when you debug with WinDbg:

  1. Start an instance of Windows Debugger.
  2. Start Microsoft Outlook.
  3. From the Debugger menu, click Debug and select "Attach to a Process..."
  4. Select MAPISP32.exe from the list of processes and click Select.
  5. From the File menu, select the File and choose "Open Source File ..." to load a source code file from your project in which you want to set a breakpoint.

Additionally, you could load a second instance of Microsoft Visual C++ program to host your transport provider's project, so that you can edit and recompile your code. Make sure to stop and restart Microsoft Outlook when you recompile.



Modification Type:MinorLast Reviewed:8/25/2005
Keywords:kbhowto kbMsg KB200026