Function Executor Concepts
This section contains the following topics:
Overview
Function Executor runs on Windows. With this interactive utility, you can learn how Btrieve operations work. Btrieve operations are the same as MicroKernel Engine operations.
By allowing execution of Btrieve operations one at a time, Function Executor enables application developers to simulate the operations of a Btrieve application. This simulation can isolate the database calls from the rest of your application, which can help in testing and debugging your program.
Function Executor is primarily a tool for application developers. This chapter assumes that you have a basic knowledge of Btrieve operations. For more information about Btrieve operations, refer to the Btrieve API Guide that is available in the Developer Reference.
What Function Executor Can Do
Function Executor Features
Function Executor features include the following:
Editor Status Bar
The status bar contains the following elements:
Statistics
Clicking the File Statistics icon displays a dialog box listing statistics for the currently open file. You can print these statistics to a text file or save them to a description file usable by BUTIL -CREATE. You may also create a new blank file with the same characteristics.
 
Get and GetExt
From the Get menu, you can retrieve the First, Next, Previous, and Last records in the table. The GetExt menu includes the Goto Percent, Get Position, and Find Percent commands.
The Get and GetExt commands are available from both the menu bar and toolbar. The toolbar offers Step (Physical) and Get (Logical), allowing you to move either through the natural order of the file (physical) or in a specific order (logical).
Goto Percent allows you to choose whether to jump to a point within the physical layout of the file, or down any key path, limited to the keys defined in the file. You can also set lock biases using the option buttons in the Locks group box.
 
Find Percentage is the opposite of Goto Percent. It tells you how far into the data you are, depending on whether you are stepping through the file logically or physically.
 
 
Transaction Toolbar
The Transaction toolbar lets you start, stop, and abort transactions. You can set all aspects of the Transaction API through this toolbar, and the operation is executed immediately. The Transaction status also appears on the main window status bar, since it affects all open files for the client ID.
Login Dialog
The Login dialog box allows you to perform the Btrieve login operation via a GUI interface. See the following topics for more information about the Login dialog box:
History Log
When you perform operations using the Function Executor utility, they are recorded in a History log. You can use this log to perform the operations contained therein, or save the history as a file that you can later reload and step through.
See the following topics for more information about the History log:
Viewing as Any Data Type
When a file is open, you can right-click any position in the buffer and select Show As. A dialog box appears in which you can view the bytes at the chosen buffer position as any data type.
 
Table 60 lists controls available Function Executor.
Automatic Mode in Function Executor
For each open file (see Application Window), you have the option of performing Btrieve operations with or without the assistance of Function Executor. You do not need to make any configuration changes to use one method or the other. Whether you use automatic mode or manual mode depends on which GUI controls you use.
Figure 9 Automatic Mode and Manual Mode Controls
*Note: Selections from the menus (see Application Window) also are part of the automatic mode.
When you click a button in the automatic mode area, the following assistance is provided by the utility:
Where to Learn More
Function Executor is a valuable tool for program developers, but it assumes you have a working knowledge of Btrieve fundamentals. Refer to the following topics to understand all the features of this utility:
The chapter MicroKernel Engine Fundamentals in PSQL Programmer's Guide. That guide is part of the PSQL Developer Reference.
The chapter Btrieve API Operations in Btrieve API Guide. That guide is part of the PSQL Developer Reference.