Syntax. RTD(progID,server,topic1,[topic2],...)
Definition. This function retrieves real-time data from a program that supports COM automation.
Arguments
progID (required). A string specifying the class name (progID) of a registered COM automation add in.
server (optional). The computer on which the add-in will run. This can be a local computer or a network computer.
topic1, [topic2],... (the first parameter is required). Parameters that specify the requested real-time data.
Background. If this function cannot find a valid real-time data server, it returns the #N/A
error.
If the server is a local computer, you can omit this argument (enter a space between the commas) or specify an empty string. If you use this function in Microsoft Visual Basic for Applications (VBA), the empty string (vbNullString) is mandatory.
The user of the workbook will need access to the COM add-in components on the network computer, and the DLL file must be locally registered.
With VBA, a real-time server can be accessed only by using the Microsoft Office Developer Edition (for versions of VBA before Office XP) and Visual Basic 6, or a programming language in Microsoft Visual Studio .NET until its 2010 version.
Example. The exampleRTD.dll file is located in the Chapter10 folder with sample files. To register this file, click the Start button on the taskbar, type cmd to get the command line box, and type regsvr32.exe drive:pathfile name (the u parameter will unregister the file). This DLL file returns the real-time data for the hour, minute, and second.
You can use the server with the following formulas:
=RTD("RealTime.clsRTDS",,"hour") =RTD("RealTime.clsRTDS",,"minute")
or
=RTD("RealTime.clsRTDS",,"second")
3.14.246.148