Specifications
188 Chapter 16
ESA/PSA Programming Examples
Using Visual Basic® 6 to Capture a Screen Image
ESA/PSA Programming Examples
Using Visual Basic
®
6 to Capture a Screen
Image
This is a Visual Basic example that stores the current screen image on
your PC. The program works with the ESA or PSA Series spectrum
analyzers. The bas file (screen.bas) and a compiled executable
(screen.exe) can be found on the Documentation CD.
This example:
1. Stores the current screen image on the instrument’s flash as
C:PICTURE.GIF.
2. Transfers the image over GPIB or LAN and stores it on your PC in
the current directory as picture.gif.
3. The file C:PICTURE.GIF is then deleted from the instrument’s
flash.
NOTE This example uses GPIB address 18 for the spectrum analyzer.
’’ """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
’’ Copyright (c) 1999- 2003 Agilent Technologies Inc. All rights reserved.
’’
’’ You have a royalty-free right to use, modify, reproduce and distribute
’’ the Sample Application Files (and/or any modified version) in any way
’’ you find useful, provided that you agree that Agilent Technologies has
’’ no warranty, obligations or liability for any Sample Application Files.
’’
’’ Agilent Technologies provides programming examples for illustration only,
’’ This sample program assumes that you are familiar with the programming
’’ language being demonstrated and the tools used to create and debug
’’ procedures. Agilent Technologies support engineers can help explain the
’’ functionality of Agilent Technologies software components and associated
’’ commands, but they will not modify these samples to provide added
’’ functionality or construct procedures to meet your specific needs.
’’ """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
’’ To develop VISA applications in Microsoft Visual Basic, you first need
’’ to add the Visual Basic (VB) declaration file in your VB project as a
’’ Module. This file contains the VISA function definitions and constant