You MIGHT find that adding the RouterProxy Object to your project triggers DEP to close your application when you call StartListening()!
DEP (Data Execution Prevention) is a security feature implemented in the Windows Operating Systems starting with Windows XP (Service Pack 2) and Windows Server 2003 to inhibit the use of dynamic memory buffers for running code. Designed primarily to prevent malicious software from running on computers it can also affect software programs that access the internet or make network API calls to open TCP/IP connections or gather TCP/IP information on a computer/server (Like an HL7 message listener or router!).
Since this feature is so new, most casual windows users (and many network administrators) are unaware that it even exists. If DEP is affecting any EasyHL7 software the symptoms will be pretty dramatic. For example, the application might just shut down when you try to start it. You might get NO WARNING from windows at all! When you try and start your profiles running it might be the same, they may not start, or may start and immediately stop again with nothing to indicate why.
Even GETTING to the DEP settings on a computer is counter-intuitive. The easiest way we've found is to 'RIGHT CLICK' on 'My Computer' in MS Windows Explorer and then click 'Properties' in the right click menu. In the System Properties dialog box click the 'Advanced' tab. In the 'Advanced' tab click the 'Settings' button in the 'Performance' section (see below). This will open the 'Performance Options' Dialog box
system properties dialog box
performance options dialog box
If the radio button with the text 'Turn on DEP for essential Windows programs and services only' is checked then DEP may not be the cause of the problem.
If however, the radio button with the text 'Turn on DEP for all programs and services except those I select' is checked then you probably need to your program to the list