-
Book Overview & Buying
-
Table Of Contents
Tcl 8.5 Network Programming
Using XML-RPC to call commands remotely from Tcl is trivial. A new Tcl command will be created for each method, which makes invoking remote functions almost the same as invoking local commands.
As mentioned earlier, invoking any XML-RPC command requires knowing the available remote methods and their definitions. We also need to know the address of the remote service.
Invoking a command using XML-RPC will look similar to:
![]() |
All requests are sent over HTTP or HTTPS to the remote application, building an XML-RPC message and sending it in the request. The response is also XML-RPC content and is then parsed by the XMLRPC package.
In order to perform any XML-RPC operations in Tcl, we first need to load the XMLRPC package:
package require XMLRPC
Invoking commands over XML-RPC requires us to define the names of functions, which we want to invoke as well as list all the input parameters that they take. The XMLRPC package will then create a Tcl...
Change the font size
Change margin width
Change background colour
