Programming
325
• Using User Menu Function
Other topics about Using Macro
Macro Using COM
When you want to control the E4990A internally, you can use COM objects
alone or in conjunction with SCPI commands and the Parse object. The
latter method is a little slower than the former method because the Parse
object is used to parse the messages of SCPI commands.
Example: Using COM object
Dim Ana
set Ana = CreateObject("E4990.Application")
Ana.scpi.display.split = "D12_34"
Ana.scpi.display.window(2).activate
Example: In conjunction with SCPI commands and the Parse object
Dim Ana
set Ana = CreateObject("E4990.Application")
Ana.parse "DISP:SPLIT D12_34"
Ana.parse "DISP:WIND2:ACT"
You can use this with VB Script. If you install the Excel (Excel VBA) or
other programmable software in the E4990A, It also can control the
E4990A.
Executing Macro from Softkey/Hardkey
Macros are executable programs that you write, load into the analyzer, and
then run from the analyzer. Macros (.vbs and .exe) can be executed by
clicking its file on the file explore. However, you can execute it from
Softkey or Hardkey. You can have up to 25 macros set up to run on the
analyzer.
Registering your macro
1. Press Macro Setup > Macro Setup ... .
2. Click Edit to start the Edit Macro Setup dialog.
3. In the Macro Title box, type a descriptive title for your macro.
4. Click Browse.
5. Find and select your executable file. Change Files of Type if
necessary.
6. Click OK on the Edit Macro Setup dialog.
7. Change the order by Up or Down keys as necessary.