PRB: NetDDE Fails to Connect Under Windows 95 (131025)
The information in this article applies to:
- Microsoft Win32 Application Programming Interface (API), when used with:
This article was previously published under Q131025 SYMPTOMS
An application using Network Dynamic Data Exchange (NetDDE) fails to
connect to another DDE application on another computer.
CAUSE
One of the reasons could be that NETDDE.EXE (a system component) is not
running.
Network Dynamic Data Exchange (NetDDE) allows two DDE applications to
communicate with each other over the network. In Windows for Workgroups,
the NETDDE.EXE (a system component) was loaded by default. However under
Window 95, NETDDE.EXE is not loaded by default.
RESOLUTION
An application using the netDDE services should check if the netDDE system
component is loaded. if NETDDE.EXE isn't running, the application should
run it.
Sample Code
The following sample code checks to see if NETDDE.EXE is loaded and tries
to load it if necessary. The sample code works for both 32-bit and 16-bit
applications.
BOOL IsNetDdeActive()
{
HWND hwndNetDDE;
// find a netDDE window
hwndNetDDE = FindWindow("NetDDEMainWdw", NULL);
// if exists then NETDDE.EXE is running
if(NULL == hwndNetDDE)
{
UINT uReturn;
// otherwise launch the NETDDE.EXE with show no active
uReturn = WinExec("NETDDE.EXE", SW_SHOWNA);
// if unsucessful return FALSE.
if(uReturn <= 31)
return FALSE;
}
// NetDDE is running
return TRUE;
}
STATUS
This behavior is by design.
Modification Type: | Major | Last Reviewed: | 10/30/2003 |
---|
Keywords: | kbAPI kbcode kbnetwork kbprb KB131025 |
---|
|