Technical data
Creating and Downloading User-Data Files 5
Agilent N8211A/N8212A Performance Upconverter Synthetic Instrument Module, 250 kHz to 20 / 40 GHz 135
5
Type csc.exe State_Files.cs at the command prompt and then press the Enter key on the
keyboard to run the program. The following figure shows the command prompt
interface.
The State_Files.cs program is listed below. You can copy this program from the examples
directory on the signal generator’s CD–ROM.
The State_Files.cs example uses the ESG in the programming code but can be used with
the PSG or Agilent MXG.
//****************************************************************************************
// FileName: State_Files.cs
//
// This C# example code saves and recalls signal generator instrument states. The saved
// instrument state files are written to the local computer directory computer where the
// State_Files.exe is located. This is a console application that uses DLL importing to
// allow for calls to the unmanaged Agilent IO Library VISA DLL.
//
// The Agilent VISA library must be installed on your computer for this example to run.
// Important: Replace the visaOpenString with the IP address for your signal generator.
//
//****************************************************************************************
using System;
using System.IO;
using System.Text;
using System.Runtime.InteropServices;