Deployment

First, install .NET Framework 3.5 on the machine you will use to run the WHSMailHost application, if it isn't already. Then, copy the WHSMailHost.exe, WHSMailHost.exe.config, and WHSMailCommon.dll files to a directory on this machine. You might want to create a shortcut in the Startup group so it will launch automatically when you log into Windows.

Next, open Outlook and select Tools→Trust Center. Choose Programmatic Access, and set the option to "Never warn me about suspicious activity", as shown in Figure 7-12. Unfortunately this security measure must be disabled; otherwise, Outlook will prompt you every time the host process attempts to retrieve any data. There is no way to bypass this on an application-by-application basis, so we have to turn it off for all applications.

Programmatic Access Security in Outlook 2007

Figure 7-12. Programmatic Access Security in Outlook 2007

Note

If you are running Windows Vista, you must run Outlook as an Administrator in order to change this setting. Once changed, you may go back to running Outlook as a standard user.

If you are running firewall software on the PC, ensure that port 12345 will allow traffic to pass through. You may also change port 12345 to a different port, but you must change it in the configuration files for both applications.

Finally, note that Outlook does not need to remain open to use this application. You do, however, need to be logged into the machine with the ...

Get Coding4Fun now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.