Article ID: 160957 - Last Review: June 14, 2007 - Revision: 2.1 INFO: DDE Support in Internet Explorer VersionsThis article was previously published under Q160957 On This PageSUMMARY
Several years ago Spyglass Inc. defined a Software Development Interface
(SDI) that has served as the basis for most common interprocess
communication (IPC) support in current browsers.
The SDI is composed of a number of generic, platform-independent verbs that are implemented through platform-specific transports. For Internet Explorer (IE) running in the Microsoft Windows environment, that platform-specific transport is DDE. The 16-bit versions of Internet Explorer for Windows 3.1 and Windows NT 3.51 very closely followed this Spyglass specification. Versions 2.x and 3.x of the 16-bit Internet Explorer supported the entire list of topics as well as parameters outlined in the spec. If your application specifically targets the 16-bit version of Internet Explorer, please refer to the Spyglass SDI specs above for more information on its DDE support. On the other hand, the 32-bit versions of Internet Explorer supported only a subset of the topics described in the Spyglass SDI specification. This article specifically lists this subset of topics supported by the 32-bit Internet Explorer versions, as well as relevant DDE-specific information for each of these topics. MORE INFORMATION
Most of the information below applies to the 32-bit versions of Internet
Explorer, unless specifically indicated.
In each of the following DDE transactions, you need to specify the following: Note that all strings passed to DDEML using DdeCreateStringHandle are limited to 255 characters. When passing item names to any of the topics described below, strings greater than 255 characters long are truncated. OpenURLOpenURL retrieves a URL off the Web and displays it, based on specified WindowID:topicName: WWW_OpenURL itemName : URL <Example: "<WWLINK TYPE="GENERIC" VALUE="http://www.microsoft.com">">http://www.microsoft.com"></WWLINK> returnValue: -2 for acknowledgment, -3 for error Note that when specifying the URL for the 16-bit version of Internet Explorer, be sure to specify the full URL, including the protocol, for example: For more information about developing Web-based solutions for Microsoft Internet Explorer, visit the following Microsoft Web sites: http://msdn.microsoft.com/ie/
(http://msdn.microsoft.com/ie/)
instead of "www.msdn.microsoft.com";
otherwise, the OpenUrl call will fail.
http://support.microsoft.com/iep (http://support.microsoft.com/iep) For IE4, itemName can be specified as follows: itemName: URL,[FileSpec],WindowID <Example: "<WWLINK TYPE="GENERIC" VALUE="http://www.microsoft.com",,0>">http://www.microsoft.com",,0></WWLINK> Note that the second parameter, FileSpec, specified in the SDI spec, is ignored, and is, therefore, not specified in the itemName example above. All other parameters following the WindowID parameter that are not specified above are similarly ignored. Specifying a WindowID of 0 tells the browser to open a new window; whereas, -1 opens the URL in the most recently active browser window. ShowFileShowFile passes FileSpec to be rendered in a given WindowID:topicName: WWW_ShowFile itemName: FileSpec returnValue: -2 for acknowledgment, -3 for error All other parameters are ignored. ActivateWindowRegardless of the WindowId specified, ActivateWindow brings the most recently active browser window to the foreground:topicName: WWW_Activate itemName: WindowID <any value> returnValue: WindowID Note that the WindowID returned is synthetic; that is, it can only be used in other DDE transactions with Internet Explorer. It should not be assumed as an HWND. ExitExit tells the browser to shut down and exit:topicName: WWW_Exit itemName: WWW_Exit returnValue: 0 RegisterURLEchoRegisterURLEcho requests that ApplicationName be notified of URLEcho events whenever a URL gets loaded. Multiple servers can be registered to get these notifications:topicName: WWW_RegisterURLEcho itemName: ApplicationName (enclosed in double quotes) returnValue: Non-Zero for success, 0 for failure topicName (hsz1): WWW_URLEcho itemName (hsz2): URL,MIMEType,WindowID <Example: "<WWLINK TYPE="GENERIC" VALUE="http://www.home.com","text/html",-1>">http://www.home.com","text/html",-1></WWLINK> Transaction: XTYP_POKE NOTE: WWW_RegisterURLEcho and WWW_UnRegisterURLEcho are new to IE 3.01. An application using IE 3.0 may need to upgrade to IE 3.01 to take advantage of this functionality. UnRegisterURLEchoUnRegisterURLEcho terminates associated request for URLEcho events notification:topicName: WWW_UnRegisterURLEcho itemName: ApplicationName (enclosed in double quotes) returnValue: 0 RegisterProtocolRegisterProtocol registers the DDE Server application, Server.exe, to handle URLs of a specific Protocol type:topic Name: WWW_RegisterProtocol item Name: AppName,Protocol <Example:"AppName","mailto"> Note that each of the strings have to be explicitly enclosed in double quotes. For Example, in C, the same string will have to be specified as follows: "\"AppName\",\"mailto\"" returnValue: Non-Zero for success, 0 for failure topic Name (hsz1): WWW_OpenURL item Name (hsz2): URL,[FileSpec],WindowID,Flags <Example:"mailto:billg@ms.com",,-1,0> Transaction: XTYP_REQUEST Note that Flags is currently undefined and is always set to 0. In order to convert hsz1 and hsz2 into strings, the function DdeQueryString needs to be called. Note that, as indicated in the specification, a protocol can be registered to only one DDE server application at a time. In this case, only the application Server.exe will get notifications from the browser whenever the user clicks on any "mailto:" reference on a Web page. NOTE: As of Internet Explorer 4.0, RegisterProtocol (and UnRegisterProtocol) are no longer supported. The replacement technology for DDE in this regard is "Asynchronous Pluggable Protocols." See the REFERENCES section. UnRegisterProtocolUnRegisterProtocol terminates associated request for protocol notification:topicName: WWW_UnRegisterProtocol itemName: ApplicationName (enclosed in double quotes) returnValue: 0 ListWindowsAccording to the Spyglass specification, returns a list of window IDs for windows currently used by the browser:topicName: WWW_ListWindows itemName: WWW_ListWindows returns: NumItemsInTheList,ArrayOfWindowIDs (ie [count,winID,winID,winID]) 191508
(http://support.microsoft.com/kb/191508/EN-US/
)
PRB: Confusing Return Values from DDE topic WWW_ListWindows
GetWindowInfoReturns URL and WindowText currently being displayed in the browser window:topicName: WWW_GetWindowInfo itemName: WWW_GetWindowInfo returnValue: URL,WindowText <Example: "<WWLINK TYPE="GENERIC" VALUE="http://www.microsoft.com/","Microsoft">http://www.microsoft.com/","Microsoft</WWLINK> Home Page"> Summary TableThe following table summarizes the DDE topics that are supported by various versions of Internet Explorer:"SpyGlass" indicates that the topic is described in the SpyGlass specification located at WWW.SPYGLASS.COM (search for "SDI").
16bit 16bit SP1 Beta
3.02 3.03 4.0 4.0 4.01 4.01 5.0
DDE Topic Status * 1712 PP2 2106 3110 626
___________________________ ________ __________________________________
WWW_Activate SpyGlass X X X X X X X
WWW_BeginProgress SpyGlass X
WWW_CancelTransaction SpyGlass X X
WWW_EndProgress SpyGlass X
WWW_Exit SpyGlass X X X X X X X
WWW_GetWindowInfo SpyGlass X X X X X X X
WWW_ListWindows SpyGlass X X X X X X X
WWW_MakingProgress SpyGlass X
WWW_OpenURL SpyGlass X X X X X X X
WWW_OpenURLResult SpyGlass X
WWW_ParseAnchor SpyGlass X X
WWW_QueryVersion SpyGlass X X
WWW_RegisterAppClose SpyGlass X
WWW_RegisterDone SpyGlass X X
WWW_RegisterProtocol SpyGlass X X
WWW_RegisterURLEcho SpyGlass X X X X X X X
WWW_RegisterViewer SpyGlass X X
WWW_RegisterWindowClose SpyGlass X X
WWW_SetProgressRange SpyGlass X
WWW_ShowFile SpyGlass X X X X X X X
WWW_UnRegisterAppClose SpyGlass X
WWW_UnRegisterProtocol SpyGlass X X
WWW_UnRegisterURLEcho SpyGlass X X X X X X X
WWW_UnRegisterWindowClose SpyGlass X X
WWW_UnRegisterViewer SpyGlass X X
160976
(http://support.microsoft.com/kb/160976/EN-US/
)
How to Control the Currently Running Instance of IE3 via DDE
191508
(http://support.microsoft.com/kb/191508/EN-US/
)
Confusing Return Values from DDE topic WWW_ListWindows
REFERENCES
"Software Development Interface" document at WWW.SPYGLASS.COM
For more information about developing Web-based solutions for Microsoft Internet Explorer, visit the following Microsoft Web sites: http://msdn.microsoft.com/ie/
(http://msdn.microsoft.com/ie/)
http://support.microsoft.com/iep (http://support.microsoft.com/iep) APPLIES TO
| Article Translations
|


Back to the top
