Server Sample: DDE Server

Click to open or copy the Server project files.

This module serves to demonstrate one way a sophisticated DDE server that uses enumerable topics and items might be implemented. It takes full advantage of application-owned data handles (when fAppowned is set) to minimize the need for repeated rendering of data when shared with multiple clients.

The server supports full system topic information plus help and nonsystem topic item enumeration for the benefit of browsing clients that are wondering what's available.

This server can be made secure by altering the conversation context filter.

This server can appear to support alternate codepages and languages by altering the conversation context filter. On Windows this is moot since there is not yet a clearly defined way of doing international communication and because the atom manager restricts what topic and item strings can be used on the system.

Building SDK Samples

This sample uses the following keywords:

_stscanf; _tcscat; _tcschr; _tcscpy; _tcslen; beginpaint; checkhugedata; checkmenuitem; checkradiobutton; contextdlgproc; createhugedatahandle; createwindow; ddeaccessdata; ddeadddata; ddecallback; ddecmpstringhandles; ddecreatedatahandle; ddecreatestringhandle; ddedisconnect; ddeenablecallback; ddefreedatahandle; ddefreestringhandle; ddegetdata; ddeimpersonateclient; ddeinitialize; ddenameservice; ddepostadvise; ddeunaccessdata; ddeuninitialize; defwindowproc; delay; dialogboxparam; dispatchmessage; dodialog; drawtext; drawtextline; enddialog; endpaint; freeprocinstance; getclientrect; getcurrenttime; getdc; getdlgitemint; getdlgitemtext; getfocus; getmenu; getmessage; gettextmetrics; getversion; helpxfer; hszize; initapplication; initinstance; intersectrect; invalidaterect; isdlgbuttonchecked; itemlistxfer; loadcursor; loadicon; mainwndproc; makeintresource; makelong; makeprocinstance; min; myrand; offsetrect; paintserver; peekmessage; postmessage; postquitmessage; rand; randtest; registerclass; registerclipboardformat; releasedc; renderdelaydlgproc; reverttoself; sendmessage; setbkmode; setdlgitemint; setdlgitemtext; setfocus; setmyrand; setserverdlgproc; settopicdlgproc; setwindowtext; showwindow; srand; sysformatsxfer; testcountxfer; testhugexfer; testrandomxfer; text; topiclistxfer; translatemessage; unhszize; unregisterclass; updatewindow; validatecontext; winmain; wsprintf