User`s guide

Table Of Contents
184 Chapter 12
Sample Application Programs
Controlling Using Telnet Server
Controlling Using Telnet Server
This section describes how to control the E5061A/E5062A using WinSock API in the
Windows environment, with a sample program written in Visual Basic (VBA macro). You
can find the source file of this program, named ctrl_lan.xls (Microsoft Excel file), on the
sample program disk.
Using VBA macro
Opening ctrl_lan.xls in Microsoft Excel display a screen as shown in Figure 12-5.
Figure 12-5 ctrl_lan.xls
For how to use each element in Figure 12-5, refer to the following description.
We begin describing the part 1. Enter the version number of WinSock API in the cell right
side of “Winsock Version.” The version number is obtained by multiplying 256 by the
major version then adding the minor version. For example, when the version of your
Winsock API is 1.1, the version number is obtained as follows: 256×1+1=257. Enter the IP
address of the E5061A/E5062A in the cell right side of “IP Address.” This VBA macro
will not work properly without appropriate values in the two cells.
In the part 2, sweep range (start and stop points) and number of measurement points are set.
Clicking the button labeled as “Set” executes setting operation as specified with the setting
table, while clicking the button labeled as “Query” retrieves the current settings of the
E5061A/E5062A.