-
HP Data Entry and Forms Management System (VPLUS) Reference Manual HP 3000 MPE/iX Computer Systems Edition 6 Manufacturing Part Number: 32209-90024 E0300 U.S.A.
-
Tables Notice The information contained in this document is subject to change without notice. Hewlett-Packard makes no warranty of any kind with regard to this material, including, but not limited to, the implied warranties of merchantability or fitness for a particular purpose. Hewlett-Packard shall not be liable for errors contained herein or for direct, indirect, special, incidental or consequential damages in connection with the furnishing or use of this material.
-
Contents 1. VPLUS Overview Product Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Interface Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Transaction Processing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Source Data Entry . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
-
Contents Interrupting Data Entry . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .49 Terminating a Session . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .50 Unexpected Program Interruption . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .50 Viewing and Modifying Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
-
Contents Fields . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96 FORM FUNCTION KEY LABELS MENU . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98 FORM LAYOUT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 FIELD MENU . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
-
Contents LOCALEDITS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .140 Syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .140 Parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .140 Discussion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
-
Contents Transparency . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Choice . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Range . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Grouping and Optional . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
-
Contents Discussion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .167 Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .167 UPSHIFT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .168 Syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
-
Contents Combining Data from Several Forms. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Separating Data into Several Records . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Reformatting Repeating Forms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Separating Data from One Batch File into Several Output Files . . . . . . . . . . . . . . . . . . . Using REFSPEC. . . . . . . . . . . . . . . .
-
Contents Multilanguage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .227 Error Detection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .228 HOW INTRINSICS ARE USED . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .230 Form Definition Area . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
-
Contents VGETSCPDATA . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . VGETSCPFIELD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . VGETtype . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . VGETYYYYMMDD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
-
Contents COPY . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .375 DELETE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .376 EXIT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .377 FIELD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
-
Contents FORTRAN 77 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . BASIC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . TRANSACT. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . PASCAL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
-
Contents VCHANGEFIELD Messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .541 VPLACESURSOR Intrinsic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .541 INFO Intrinsic Messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .541 Forms Loading Messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
-
Contents G. TERMINAL INFORMATION SUPPORTED TERMINALS AND FEATURES . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Termtypes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Modified Data Tag . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Extended Local Edits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
-
Contents Rename Forms File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .616 Convert KSAM File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .616 Adjust Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .618 HP32209 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
-
Contents Returning Data to the Program . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Closing Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . VPLUS Enhancements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HPTOUCH Support (Introduced on VPLUS B.04.10 in MPE G.01.01) . . . . . . . . . . . . . . .
-
Contents 18
-
Figures Figure 1-1.. Overview of VPLUS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 Figure 1-2.. FORMSPEC Form Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 Figure 1-3.. FORMSPEC Screen Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 Figure 1-4.. Sample Field Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 Figure 1-5..
-
Figures Figure 3-32.. Data Capture Device Specifications Menu . . . . . . . . . . . . . . . . . . . . . . . . . . 121 Figure 3-33.. Form Layout in FORMSPEC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123 Figure 3-34.. Displayed on Standard Character Set Mini-CRT Screen . . . . . . . . . . . . . . 123 Figure 3-35.. Displayed on 32 Character One Line Alpha Display Screen . . . . . . . . . . . . 123 Figure 3-36.. Displayed on Large Character Mini-CRT Screen. . . . . . . . . . . .
-
Tables Table 2-1.. Function Keys for Entry . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40 Table 3-1.. FORMSPEC Key Labels . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56 Table 3-2.. FORMSPEC Reserved Word List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 Table 3-3.. Display Enhancement. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 Table 3-4..
-
Tables Table 6-10.. Field Information Buffer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281 Table 6-11.. File Information Buffer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284 Table 6-12.. Form Information Buffer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 287 Table 6-13.. Numeric Type Conversions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 301 Table 6-14..
-
VPLUS Overview Product Overview 1 VPLUS Overview This chapter provides overview information about using VPLUS and also provides information about using this manual. Product Overview VPLUS is a comprehensive software system that provides an interface between a terminal and any transaction processing program. The interface can support the formatting, editing, and validation of data as well as the display and collection of that data.
-
VPLUS Overview Product Overview The collection and reformatting capability, either singly or combined, provide a method of adding interactive source data collection to existing batch applications. Features The primary features of the VPLUS system are: • A forms design program (FORMSPEC) that allows quick and easy interactive forms design using menus. • Batch mode management of forms files, through FORMSPEC, that allows a forms file to be updated, compiled, and listed in a background job.
-
VPLUS Overview Product Overview Figure 1-1. Overview of VPLUS DEFINITION DATA FORMSPEC FORMS AND DATA EDITING DATABASE FILE VPLUS INTRINSICS Entry or Application DATA ENTRY HP 3000 CAPABILITIES REFSPEC REFORMATTING SPECS REFORMAT OUTPUT Designing Forms With FORMSPEC FORMSPEC enables you to design forms ranging from simple to complex. FORMSPEC keeps forms in a special file, called a forms file. A forms file can have one or many forms.
-
VPLUS Overview Product Overview Levels of Forms Design FORMSPEC has four complexity levels of forms design: Simple Collection You specify the form layout and FORMSPEC allows any character set codes that you enter. This level keeps the default field attributes and does not require any other FORMSPEC editing or formatting capabilities.
-
VPLUS Overview Product Overview options, such as appending to the current form. Chapters 3 and 4 instruct you about specifying whether the current form is to be repeated, or repeated and appended to itself. Figure 1-2. FORMSPEC Form Menu FORMSPEC v.uu.
-
VPLUS Overview Product Overview Figure 1-3. FORMSPEC Screen Design *****ABC MANUFACTURING***** Date: [ordate Order Number: [ordnum] SHIP TO: Name Address City Zip [name [address [city [zip QTY. PART NO. qty.. partnum. PREV FORM NEXT FORM ] ] Telephone State [phone ] ] ] [st] ] DESCRIPTION UNIT PRICE description............................uprice. REFRESH PREV NEXT MAIN/ RESUME TOTAL PRICE tprice. EXIT Simple Editing You can edit each field of a form by using the Field Menus.
-
VPLUS Overview Product Overview Figure 1-4. Sample Field Menu FORMSPEC v.uu.ff Field Menu QTY. PART NO. qty.. partnum. Num [n Len [n ] FORM NAME: SHIPTO DESCRIPTION UNIT TOTAL PRICE PRICE uprice. tprice. description............................ ] Name [ fieldtag ] Enh [ HI ] FType [ 0 ] DType [ ] Initial Value *** Processing Specifications *** PREV FORM NEXT FORM REFRESH PREV NEXT MAIN/ RESUME EXIT Data Type This attribute controls the type of data allowed in the field.
-
VPLUS Overview Product Overview values entered in fields F1 and F4, or between 100 and 300, inclusive. Table Check The value entered must be in (or not in) a table of values. For example, IN 5,10,15,F7+5 means the value must be 5, 10, 15, or the current value of field F7 plus 5. Pattern Check The value entered must match a particular pattern. For example, MATCH Aaa-ddd means the value must start with the letter "A" and be followed by two alphabetic letters, a hyphen, and three digits.
-
VPLUS Overview Product Overview Advanced Processing Statements The advanced processing statements provide: Data Movement You can set any field to a particular value, or to a value moved from another field. Default formatting of the data is performed during movement according to the data type of the destination field. For example, SET TO !JUNE 17,1999! moves the date constant (which must be delimited by exclamation points) to the current field.
-
VPLUS Overview Product Overview error enhancements and the placement of the error/status line on the form. You can change these default characteristics using the Globals Menu. Application-Ready Buffer An application-ready buffer (ARB) is a buffer passed between the application and the run-time intrinsics for data collection and display. It performs the following functions: • Holds data as the application will use it, which may differ from how it appears on the screen.
-
VPLUS Overview Product Overview useful to the application program. The data transformations may be predefined for the entire buffer in the forms file using FORMSPEC (the ARB). If field-by-field movement is used, the transformation type is specified by the intrinsic name. Data Transformation These intrinsics gather data entered by the user at the screen and transform it into the format most useful to the application, or vice versa.
-
VPLUS Overview Product Overview Entering Data with ENTRY VPLUS features a standalone data entry program, called ENTRY. Forms and data specifications are created using FORMSPEC. This program does the following: • Displays forms at the terminal • Accepts and validates data entered on the forms • Writes the data to a batch file ENTRY operates in two modes: data collection and browse/modify.
-
VPLUS Overview Product Overview Browse/Modify The user can view the data already written to the batch file by requesting browse/modify mode. The user requests this mode by pressing a terminal function key. The same key returns the user to data collection mode at the point of interruption. When browse/modify is requested, the previous data record written to the batch file is displayed on the form through which it was entered. The user can examine the data, change it if desired, and then press Enter.
-
VPLUS Overview Product Overview When you have created all of the reformat specifications, you compile the reformat file. The REFORMAT program reads data from the batch file, reformats it according to the REFORMAT file specification, and writes it to an output file. REFORMAT can be run any time after a data entry batch file has been written. It can be run from a terminal or as a batch job, requiring only the names of the batch file, the reformat file, and the output file.
-
VPLUS Overview Using This Manual Using This Manual This manual is intended for the following users: Forms Designer Designs the forms to be displayed, determines the order in which forms are displayed, and specifies any editing or special processing to be performed on data entered or displayed through the forms. Applications Programmer Designs and codes the application that uses data entered or displayed through the FORMSPEC forms.
-
VPLUS Overview Using This Manual Language Support, the applications programmer should refer to chapter 8. If the application being designed consists of data collection for later batch processing, the applications programmer should determine whether ENTRY fulfills the user's application needs. Chapter 2 describes ENTRY from the user's perspective. If the user's needs require application modifications, the applications programmer should review appendix A, "Sample Programs.
-
Entering Data with ENTRY Protected and Unprotected Fields 2 Entering Data with ENTRY This chapter describes using the VPLUS standalone data entry application, called ENTRY. The forms file you design implements the specific data collection function that your application requires. ENTRY is the execution mechanism. This chapter is intended for the operator of the ENTRY program.
-
Entering Data with ENTRY Data Reformatting Data Reformatting You run REFORMAT if the file of collected data is to be reformatted before it becomes input to another program. The data is reformatted automatically and written to a selected output file from a selected batch file containing the previously entered data. Terminal Usage You can enter data using any of the terminals listed in appendix G. Refer to the appropriate terminal reference manual for complete instructions on terminal use.
-
Entering Data with ENTRY Terminal Usage Table 2-1. Function Keys for Entry Key Key Action Data Collection Mode Key Key Action Browse/Modify Mode REFRESH Clear screen, initialize terminal, and redisplay with initial values. On terminals with local form storage, clear form storage memory and reinitialize form storage directory. Also used to recover from "Unexpected Program Interruption," as described later in this chapter.
-
Entering Data with ENTRY Running ENTRY Printing Forms and Data To print any form, simply press PRINT. In Collect mode, the current form with any initial data is printed on the line printer. Unless a specific initial value has been assigned to a particular field by the forms designer, all fields in the form are blank initially. In Browse/Modify mode, the form is printed with the data previously collected to the current record. Ordinarily, the printed form contains the data that appears on the screen.
-
Entering Data with ENTRY Running ENTRY WARNING: Forms file recompiled since this batch was created. Enter "Y" to continue: This message is issued if the forms file has been modified and recompiled since it was last used to collect data to the batch file. Enter Y to continue only if you are sure that the changes to the forms file will not invalidate data already entered in the file. Otherwise, press Return.
-
Entering Data with ENTRY Running ENTRY a larger batch file, first use the MPE :FILE command before running ENTRY: :FILE filename;DISC=numrec where filename is the name of a new batch file and numrec is the number of records you want the new batch file to have. When you run ENTRY, specify *filename as the batch file; the program will build it with the number of records you requested. You can also use FCOPY to enlarge an existing batch file. First issue the MPE :FILE command as shown above.
-
Entering Data with ENTRY Forms Sequence Forms Sequence After you specify the forms and batch files, the Head form is the first form to appear. Depending on the forms file definition, the Head form could be a menu from which you could select the particular form on which you want to enter data. If the Head form is a menu, the data you enter determines which form is displayed next.
-
Entering Data with ENTRY Forms Sequence 1. For a frozen Head form, press Enter to append the Next form, as shown in figure 2-1. The Next form is then repeated/appended whenever you press Enter. 2. Press NEXT FORM to stop repeating, clear the screen, and display the Next form. 3. Press Enter to return to the Head form.
-
Entering Data with ENTRY Entering Data Entering Data You can enter data only in unprotected fields. Depending on how the forms are designed, unprotected fields may be delimited by brackets as shown in Figure 2-1, they may be designated simply by the enhanced display as shown in Figure 2-1, or they may not be distinguished from the protected areas of the screen. Press Tab to position the cursor to the beginning of the next unprotected field. Figure 2-1. Bracketed Fields FORMSPEC v.uu.
-
Entering Data with ENTRY Entering Data Figure 2-2. Fields without Brackets FORMSPEC v.uu.ff Order Number: Batch Record #4 Mode: COLLECT Date: 100001 04/02/98 SHIP TO: Name Address City Zip QTY State Telephone PART NO. HEAD FORM DESCRIPTION PRINT REFRESH UNIT NEXT FORM BROUSE TOTAL EXIT Optional and Required Fields Fields can be defined as required or optional. If a field is required and you do not key in data, ENTRY detects an error and displays an error message.
-
Entering Data with ENTRY Entering Data Correcting Errors You can correct errors either before or after pressing Enter. If ENTRY detects an error after you press Enter, ENTRY does not write the data to the batch file until you correct all errors in the form. (Data can be changed after being written to the batch file with the Browse/Modify capability described in the section entitled "Modifying Data.") Before Pressing Enter You can examine the form for errors before pressing Enter.
-
Entering Data with ENTRY Entering Data resume data entry from the point where you had stopped. If you press EXIT before pressing Enter, data keyed into the current form is not recorded in the batch file. When you run ENTRY again with the same forms and batch files, the last form is redisplayed with any initial values, and you must retype the data into the form whose data entry you interrupted in the previous session. Terminating a Session You can terminate ENTRY by pressing EXIT to return to MPE control.
-
Entering Data with ENTRY Viewing and Modifying Data Viewing and Modifying Data You can view and modify data written to a batch file in data collection mode by using Browse/Modify mode. Invoking Browse/Modify Mode If you are currently in Data Collection mode, press BROWSE to invoke Browse/Modify mode. If you have exited from ENTRY, run the program again.
-
Entering Data with ENTRY Viewing and Modifying Data data append when you press NEXT REC. However, when you move backward by pressing PREV REC, forms originally appended are displayed one at a time with data. Modifying the Data You can modify any unprotected field by typing over the data displayed in the field. When you press Enter, the modified data is edited and written to the associated record in the batch file. Existing values are overwritten by the new values.
-
INTRODUCTION TO FORMS DESIGN 3 INTRODUCTION TO FORMS DESIGN The forms displayed to a user are designed at a terminal with the interactive program, FORMSPEC. Using FORMSPEC, the designer designs the forms and defines parameters for editing, manipulating and displaying data. Forms defined in this manner are saved in a forms file. At any time during forms design, FORMSPEC allows the designer to modify the forms in the form file.
-
INTRODUCTION TO FORMS DESIGN GETTING STARTED WITH FORMSPEC GETTING STARTED WITH FORMSPEC You execute FORMSPEC in interactive mode by entering the following command in response to the MPE colon prompt: :FORMSPEC.PUB.SYS FORMSPEC runs entirely in block mode. HP block mode terminals are placed in block mode automatically by VPLUS; refer to Appendix G for a list of supported terminals.
-
INTRODUCTION TO FORMS DESIGN GETTING STARTED WITH FORMSPEC At the Forms File Menu, you specify the name of the forms file to be created or modified, such as the example FORMSF2.PUB.ACCTG shown in Figure 3-1.; press ENTER. If the forms file does not exist, FORMSPEC prompts you to press ENTER again to confirm that you want to create a forms file. Choose an Option Once you have specified the name of the forms file and pressed ENTER, the next menu is the Main Menu, as shown in Figure 3-2.
-
INTRODUCTION TO FORMS DESIGN GETTING STARTED WITH FORMSPEC Table 3-1. FORMSPEC Key Labels Key Key Action PREV FORM f1 Display the previous Form Menu. If no forms are defined, a Form Menu with no values is displayed. NEXT FORM f2 Display the next Form Menu. If the next form is not defined, a Form Menu with no values is displayed. FIELD TOGGLE f3 Only used in Field Menus to switch between field attributes and the optional processing specifications.
-
INTRODUCTION TO FORMS DESIGN GETTING STARTED WITH FORMSPEC Menu at any time from any other menu by pressing MAIN/RESUME. You can return to the menu from which you requested the Main Menu by pressing MAIN/RESUME. In this case, the menu on the screen when MAIN/RESUME was requested is treated as the current menu. If you just entered FORMSPEC and the Main Menu is displayed, pressing MAIN/RESUME results in a display of the Globals Menu.
-
INTRODUCTION TO FORMS DESIGN GETTING STARTED WITH FORMSPEC Creating an Application-Ready Buffer (ARB) The purpose of the ARB is to allow you to transform screen data into application data and back again by converting data types between screen and application, and by reordering the fields. Once you have created a form and saved it in the forms file, you can create an application-ready buffer (ARB) for it if you choose. Not every form needs to have an ARB, you can create ARB's for selected forms only.
-
INTRODUCTION TO FORMS DESIGN GETTING STARTED WITH FORMSPEC VPLUS, by default, will format date output with 2-digit years. To change the behavior as described above, define a JCW called VSETNEXTCENTURY and set bit 15 to 1 (bits are numbered from 0 through 15). It should be noted that this option will be active for fields wide enough to hold the 4-digit year date. For other fields, 2-digit years will be used. Existing 2-digit years can be interpreted differently to handle dates in the next century.
-
INTRODUCTION TO FORMS DESIGN GETTING STARTED WITH FORMSPEC Ability to Define More than 52 Single Character Fields per Form This enhancement allows more than 52 single character fields to be defined for a Form. Currently the field tag which is defined for a field at screen design (creation) time should begin with an alphabetic character. This enhancement will allow several other characters to be used for the field tag, thus increasing the number of single character fields that can be defined for a Form.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN EASE OF FORMS DESIGN Once you have specified a forms file and the Main Menu is displayed, you are ready to use FORMSPEC to create forms. Whenever you create a new forms file, your first task is always to add a form; if you are modifying an existing file, you may want to add a form. In either case, you follow the sequence of menus shown in Figure 3-4. Refer to the menu descriptions later in this section for more information on all the FORMSPEC menus.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN Figure 3-5. Example of a Form Layout *****ABC MANUFACTURING***** Date: SHIP TO: Name Address City Zip PREV FORM [name [address [city [zip NEXT FORM ] ] Telephone REFRESH [ordate State [phone PREV NEXT ] ] ] [st] ] EXIT MAIN/ RESUME Each layout consists of two kinds of information: Fields Areas, delimited on the form, into which data will be entered by or displayed to the user. The maximum number of fields allowed on anyone form is 128.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN If the printing delimiter is to come first, use [ ESCAPE [fieldtag. . . ESCAPE ] If the printing delimiter is to come last, use ESCAPE [fieldtag. . .ESCAPE ] In the case where a field begins with ESCAPE [ and ends with ], the terminal will insert ESCAPE ] if a following field also starts with ESCAPE [. As a result VPLUS will reject the form layout. This terminal feature can be avoided by properly using the above rules for mixing delimiters.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN tag may not have more than one character. However, the field tag is also used for the field name. You may change any field name on the Field Menu. Thus, you can give a one-character tag a longer field name when the Field Menu for the field is displayed. Note that for the field tag, uppercase letters differ from lowercase letters. Thus, f1 and F1 are two different tags.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN and processing specifications. The field attributes are the two lines of fields below the portion containing the current field. For example: Figure 3-8. The Field Attributes Only the field attributes are discussed here. The processing specifications are described in Section 4. If you can use the field attributes without change, the entire form design is complete at this point.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN Assuming the first line of the field contains 79 characters, the second line contains 80 characters, and the third line contains 34 characters, the entire field is 193 characters long. This count excludes the printing brackets which delimit the beginning and the end of the field. Field Name The field tag assigned during form design is shifted up to all uppercase letters and becomes the field name. You can enter another name in this field.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN Display Enhancement You can change the enhancement for the particular field with any combination of the codes shown in Figure 3-3. Up to four of the available enhancements may be used at one time. The data capture devices do not support display enhancements. Table 3-3.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN entered, how it is formatted for data movement, and the type of operations that can be performed on the field. Screen data types impose format and edit rules for data entered on the screen. ARB data types determine how that data will be interpreted by the application. Conversions from screen data type to ARB data type and vice versa occur automatically at runtime (see VGET/PUTBUFFER in section 7). Screen Data Type.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN Data entered in a field of this type must be a positive integer. No sign, no commas, and no decimal point can be included. As with NUM data, validity checks are performed on this data type. DIG For example, 10030, 2 and 307 are all legitimate entries in a DIG field, but 10.5, 100,000 or -10 are not. IMP n A value entered in an IMP field has an assumed decimal point. The assumed decimal point is n places from the right of the value.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN The entered data is checked by VPLUS for correct format and that it is a valid date. Arithmetic operations are not allowed on date fields. Native Language Support does not affect the order of the date field. It does, however, accept the names of months and their abbreviations for each native language at run-time. For more information on Native Language Support, see Section 8.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN Figure 3-7. sets out recommended guidelines for data type conversions from screen to ARB and back. Table 3-7.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN Pascal and FORTRAN. Table 3-8. Valid Screen Data Types ARB Data Type COBOL Pascal FORTRAN CHAR PIC X (_) Packed array CHAR [.._] CHAR YMD as above as above as above DMY as above as above as above DIG as above as above as above NUM[n] as above as above as above IMP[n] as above as above as above Note: [n] represents the number of decimal digits Figure 3-9.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN The value will appear with the conventions of the native language at run-time. For more information on Native Language Support, see Section 8. Understanding Form Sequencing As shown in Figure 3-4., the Form Menu is the first menu in the sequence of menus used to define a form. On the Form Menu, as shown in Figure 3-10.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN continues until the repeat option is changed. X(1) X(1) X(2) X(1) X(2) X(3) Appended forms are particularly useful when the form is a single line that has an indeterminate number of iterations. An order entry blank, for instance, could be designed as a repeat/append form. A form that repeats without the append option (R) is cleared each time the user presses ENTER to enter data.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN 2. Current Form X -- Repeat Option = R Next Form Option = C Next Form Y -- Repeat Option = A X(1) X(2) Y(1) Y(1) Y(2) repeat X is displayed until the repeat option is terminated, then Y is displayed and appended to itself until the repeat is terminated again. 3.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN 5. Current Form X -- Repeat Option = A Next Form Option = A Next Form Y -- Repeat Option = A X(1) X(1) X(2) X(1) X(2) X(3) X(2) X(3) Y(1) X(3) Y(1) Y(2) repeat terminated screen Form X is repeated and appended until the repeat is terminated. When the first Y form is displayed, there is no more room for the first X and it is rolled off the top of the screen and deleted. As new Y forms are appended, the X forms continue to be rolled off and deleted. 6.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN deleted leaving the remaining X forms on the screen. Note that if one frozen X forms should fill the screen, the first X is rolled off and deleted to make room for the latest X, and when the first Y form is appended, the X forms are no longer frozen.
-
INTRODUCTION TO FORMS DESIGN EASE OF FORMS DESIGN Figure 3-11. Sample Forms File Layout FORMS FILE NAME = ORDENT (No GLOBALS) FORM #1 (head form) Name: SHIPTO Repeat = N <-- no repeat/append freeze/append = F <-- leave form on screen with next form Layout: Ship to: [Name [Address [City ZIP: [Zip QTY: PART NO.
-
INTRODUCTION TO FORMS DESIGN FORMS FILE FORMS FILE The forms file consists of "global" specifications that apply to all forms in the file, followed by the individual forms specification. Within each form specification, the form is identified, and its form layout is defined. The form layout defines each field into which data can be entered. Each of these different types of specification is entered on a menu displayed by FORMSPEC. (Refer to Figure 3-12. for an illustration of a prototype forms file.
-
INTRODUCTION TO FORMS DESIGN FORMS FILE created. The command should then be deleted from the processing specifications area. If any error is encountered in executing the command, it is displayed in the upper area of the Field Menu screen. #COPYFROM When #COPYFROM oldfilename is executed, the processing specifications (if any) in the file specified by oldfilename are copied into the processing specifications area of the field.
-
INTRODUCTION TO FORMS DESIGN FORMS FILE • If oldfilename cannot be opened, the following message is displayed: Unable to open old file! • If the syntax of the command is not proper, the following message is displayed: Check syntax: #COPYFROM oldfilename • If processing specifications exist for the field, the following message is displayed: Cannot do a #COPYFROM if proc specs already esist. When a new file is created with the #COPYTO command, it is created in the permanent file domain.
-
INTRODUCTION TO FORMS DESIGN FORMS FILE Figure 3-12. Forms File Prototype FORMS FILE Global specifications that apply to all forms in file.
-
INTRODUCTION TO FORMS DESIGN FORMS FILE Expand Forms File When you require the forms file to be larger than the default limit of 4000 records, you may override the FORMSPEC default size to create a new forms file using the MPE :FILE command. The :FILE command must be issued prior to the :RUN command to initiate FORMSPEC. Another method is to use the MPE :BUILD command to create a larger file and then use FCOPY to copy an existing forms file into the larger file.
-
INTRODUCTION TO FORMS DESIGN FORMS FILE of records are minimal, such a forms file can improve performance at run-time. A fast forms file can only be executed; it cannot be modified. You may however always modify the source forms file and then recompile it to a fast forms file. The forms file can also be compiled using FORMSPEC in batch mode. (See Section 7 for more information.) Renumbering a Form with Interactive FORMSPEC FORMSPEC provides an option to renumber forms interactively.
-
INTRODUCTION TO FORMS DESIGN FORMS FILE Figure 3-13. Forms File Listing ********************************************************************* * FORMSPEC Version v.uu.ff * * Wed, APR 16. 1986, 3:34 PM * * * * ORDFORM1.PUB.ACCTG * * * ************************************************************************* Forms File Status Modified: WED, APR 16, 1986, 3:25 Compiled: WED, APR 16, 1986, 3:25 Requires 5605 bytes of data space in addition to the applciation defined Comarea.
-
INTRODUCTION TO FORMS DESIGN FORMS FILE Figure 3-13. Forms File Listing (Cont) QTY PART NO.
-
INTRODUCTION TO FORMS DESIGN FORM FAMILIES FORM FAMILIES A family of forms is a collection of forms that share a common form layout but may have different field attributes, processing specifications, or form sequencing options.
-
INTRODUCTION TO FORMS DESIGN FORM FAMILIES which you wish to generate the child form. You may change any of the other Form Menu fields. Press ENTER. 3. The layout for the form you named in step 2 is displayed. Then press NEXT. Since the form layout must be the same for parent and children, pressing ENTER causes the error message "Cannot change screen, the form is a family member." to appear in the window. 4.
-
INTRODUCTION TO FORMS DESIGN FORM FAMILIES The solution to this problem of long user waiting time is to create two forms with the same form layout but different field attributes. Suppose the root or parent form of this example is named CUSTPAR, and that its form layout is as shown in Figure 3-15. below. All of the fields in this form are display only, except for the Customer ID Number field, which is required. Figure 3-15.
-
INTRODUCTION TO FORMS DESIGN Fields Fields Forms File Name Enter the name of the forms file in this field. It may consist of up to 36 characters, as shown in Table 3-10. NOTE In order to maintain (and browse or list) a forms file, the user must have exclusive write access to the file. FORMSPEC accepts only forms files that are MPE files with the file code of VFORM. If you have a forms file that is a KSAM file, created by versions of VPLUS prior to A.01.
-
INTRODUCTION TO FORMS DESIGN MAIN MENU MAIN MENU The Main Menu, as shown in Figure 3-17., is the main control menu for all FORMSPEC operations. If the forms file is new, you usually select A for Add a form. FORMSPEC then displays the menus that allow you to define your forms file, as described in "Ease of Forms Design".
-
INTRODUCTION TO FORMS DESIGN MAIN MENU Menu is displayed. This menu, as shown in Figure 3-24., allows you to specify a save field description. If you want to modify a save field, you use PREV or NEXT to locate the particular Save Field Menu specification. For more information, refer to the "Save Fields Menu" description. T--Terminal/Language Selection Menu If you specify T in the selection box and press ENTER, the Terminal/Language Selection Menu is displayed. This menu, as shown in Figure 3-31.
-
INTRODUCTION TO FORMS DESIGN MAIN MENU D--Delete Save Field To delete a save field, specify D in the Main Menu selection box, specify the save field name, and press ENTER. The field will be deleted. You should be sure there are no references to the deleted field in the processing specifications of any other field (refer to Section 4). D--Delete Form You can delete an entire form from the forms file by typing D in the selection box on the Main Menu, specifying the form name, and pressing ENTER.
-
INTRODUCTION TO FORMS DESIGN MAIN MENU "Form Families" earlier in this section. B--Go to ARB Menu To create, modify or delete an application-ready buffer (ARB), type B in the Main Menu selection box, and the name of the associated form in the ARB Menu field, and press ENTER. The form must already exist in the forms file and the data type conversion record must have been set up using the Globals menu. Construction of an ARB is discussed in detail later in this section.
-
INTRODUCTION TO FORMS DESIGN FORM MENU FORM MENU The name and characteristics of each form are specified on the Form Menu. As soon as the Menu specifications are entered, FORMSPEC displays a blank screen on which you design the layout of the form. This form layout phase establishes the field names and their characteristics. Based on the form layout, FORMSPEC then displays a Field Menu for each field established on the form. The Form Menu is displayed once for each form you define.
-
INTRODUCTION TO FORMS DESIGN FORM MENU Fields Enter a name to identify the form. The name can be from 1 to 15 characters, either letters of the USASCII alphabet (A-Z), digits (0-9), or the underline (). The first character must be alphabetic. The name can be entered using uppercase or lowercase letters, but all lowercase letters are shifted to uppercase by FORMSPEC. Thus, if you enter the name Form2, FORMSPEC changes it to FORM2.
-
INTRODUCTION TO FORMS DESIGN FORM MENU Next Form Name The next form name is entered as a standard form name or you can enter one of the following system-defined values: $RETURN Display the previous (but different) form. $HEAD Display the first form (either the first in the file or as defined on the Globals menu). $END Terminate forms display with this form. $REFRESH Display current form cleared to initial values as the next form.
-
INTRODUCTION TO FORMS DESIGN FORM FUNCTION KEY LABELS MENU FORM FUNCTION KEY LABELS MENU This menu is used to specify function key labels that will be displayed along with the form. Labels you specify replace original labels provided by VPLUS. Each label consists of two lines of eight characters each, To specify a label, enter the first line in the first field and the second line of the label in the second field in the menu. Both lines can be specified on this menu.
-
INTRODUCTION TO FORMS DESIGN FORM LAYOUT FORM LAYOUT Each form is associated with a picture that is displayed when the form is requested during execution. This picture is called the "form". You design the form on a blank display screen, as shown in Figure 3-20., using all the terminal capabilities associated with block mode. Once you have entered your headings and other text, and delimited the data fields, the form is basically designed.
-
INTRODUCTION TO FORMS DESIGN FIELD MENU FIELD MENU In case you want to assign special field characteristics, FORMSPEC displays a Field Menu, illustrated in Figure 3-21., for each field delimited during form design. Each menu displays up to three lines of the form, and marks the particular field to which the menu applies. It then displays the default field attributes of the field. The Field Menus are presented in the order the fields appear on the form layout, from left to right, top to bottom.
-
INTRODUCTION TO FORMS DESIGN FIELD MENU renumbered in screen order with the FORMSPEC batch mode command RENUMBER, as described in Section 7. Len (Display only) The length of the field as determined during form layout. Name Specify any USASCII name of up to 15 characters long; it must start with an alphabetic character and may be followed by any alphanumeric (A -Z, a-z, 0-9) or the underline (). It cannot be one of the reserved words listed earlier in Figure 3-2.
-
INTRODUCTION TO FORMS DESIGN FIELD MENU MDY Specifies data to be a date in the order month, day, year. DMY Specifies data to be a date in the order day, month, year. YMD Specifies data to be a date in the order year, month, day. When Native Language Support is used, the symbols used to indicate thousands and decimals are language-dependent. The names of months and their abbreviations are accepted for each native language at run-time. For more information on Native Language Support, see Section 8.
-
INTRODUCTION TO FORMS DESIGN GLOBALS MENU GLOBALS MENU Certain characteristics of the entire forms file are defined as global specifications and specified on the Globals Menu, illustrated in Figure 3-22. The global specifications include the default screen enhancements for fields and errors, the first form to be executed, where the message "window" line appears on the form, and provides for user-defined labels for the function keys.
-
INTRODUCTION TO FORMS DESIGN GLOBALS MENU Fields Head Form Name Enter the name of the first form you want displayed when the forms file is executed. If you leave this field blank, the first form in the forms file will be the first form displayed. Note that adding forms to the forms file may change the first form. When the forms file is compiled, this name must identify an existing form.
-
INTRODUCTION TO FORMS DESIGN GLOBALS MENU Window Enhancement The window line is normally enhanced with inverse video, half bright. If you want a different enhancement for this line, you must specify it in this box. You may enter any of the standard enhancement codes (I, H, U, B, S, and 1 - 8) in any combination, or you can specify no enhancements by entering NONE. Default Inverse video, Half bright (HI).
-
INTRODUCTION TO FORMS DESIGN GLOBAL FUNCTION KEY LABELS MENU GLOBAL FUNCTION KEY LABELS MENU This menu is used to specify new function key labels which will appear when an application is executed. Labels you specify replace original labels provided by VPLUS. Each label consists of two lines of eight characters each. To specify a label, enter the first line in the first field and the second line of the label in the second field in the menu.
-
INTRODUCTION TO FORMS DESIGN SAVE FIELD MENU SAVE FIELD MENU A save field is a global field whose value can be used anywhere in the forms file where field references are allowed. Save fields are not part of a particular form like other fields, but are "global" to all forms. Like other fields, they always contain data in external, character form. The save fields can be used by most processing statements, but are particularly useful for passing data between fields on different forms.
-
INTRODUCTION TO FORMS DESIGN SAVE FIELD MENU and the name of the save field to be deleted in the field name box. Fields Save Field Name A standard field identifier composed of up to 15 USASCII characters, beginning with an upper or lowercase letter. The remaining characters can be upper or lowercase letters, digits, or underlines. For example, SF3, D2 15, or ALPHA. Note that if you use a lowercase letter in a name, FORMSPEC shifts it to an uppercase letter.
-
INTRODUCTION TO FORMS DESIGN USING FORMSPEC TO CREATE AN ARB USING FORMSPEC TO CREATE AN ARB Once you have created a form and saved it in a forms file, you can create an associated application-ready buffer (ARB) for that form. There are two steps to the process; first, you must set up a data type conversion (DTC) record, then you can generate the ARB. The DTC record need only be set up once for the entire forms file. You may want to transform data between the screen and application for several reasons.
-
INTRODUCTION TO FORMS DESIGN USING FORMSPEC TO CREATE AN ARB Figure 3-25.
-
INTRODUCTION TO FORMS DESIGN USING FORMSPEC TO CREATE AN ARB Figure 3-26. Globals Menu FORMSPEC v.uu.ff Forms File Menu Head Form Name FORMS FILE: ] [FORM 1 Default Display Enhancement [HI ] Error Enhancement [ IU ] [ 1 ] Window Display Line [ NONE Window Enhancement ] Define Function Key Labels [ X ] (“Y”) Define Data Conversions [ Y ] (“Y”) PREV FORM filename REFRESH NEXT FORM PREV NEXT EXIT MAIN/ RESUME 2. Enter Y for "Define Data Conversions" in the last box.
-
INTRODUCTION TO FORMS DESIGN USING FORMSPEC TO CREATE AN ARB The n in the numeric types stands for a number of decimal places. When specifying a conversion to one of these types, you must replace n with a digit or a. When you set the number of decimals to a, you are instructing FORMSPEC to determine the decimals algorithmically on the basis of the source type. Note that you can only select the a option on this menu, and not on the field menus.
-
INTRODUCTION TO FORMS DESIGN USING FORMSPEC TO CREATE AN ARB Options GEN (Generate) Create an ARB from scratch, containing a field for each field on the form. The sequence of the fields accords with their sequence on the form, and can be altered using the Restructure ARB Menu Figure 3-29. The type and length of the fields are determined by comparing the screen attributes with the data conversion record. They can be changed using the ARB Field Menu. This option is only valid if no ARB exists for the form.
-
INTRODUCTION TO FORMS DESIGN USING FORMSPEC TO CREATE AN ARB The Effect of Renaming a Field on a Form There are three possibilities, which are described below. • The old name is in the ARB but the new name is not: The ARB field is renamed to the new name, retaining its "live" field type, and the screen length and screen type are altered if necessary.
-
INTRODUCTION TO FORMS DESIGN USING FORMSPEC TO CREATE AN ARB Figure 3-29. Restructure ARB Menu FORMSPEC v.uu.
-
INTRODUCTION TO FORMS DESIGN USING FORMSPEC TO CREATE AN ARB algorithmically from the length and type of the corresponding field on the form. • Live name changed to filler name (new ARB field has no corresponding field on the form): new field retains length and type of old ARB, and screen length becomes zero and type blank. • Filler name changed to filler name (new ARB field has no corresponding field on the form): new field retains length and type of old ARB, and screen length remains zero and type blank.
-
INTRODUCTION TO FORMS DESIGN USING FORMSPEC TO CREATE AN ARB Using and Defining ARBs The programmer is responsible for: • Using the correct data types for each programming language; for example, REAL is invalid for COBOL applications. • Aligning and/or padding the ARB/source code. If an odd number of bytes is followed by an integer, some languages, including Pascal and FORTRAN, automatically pad the record definition, forcing the integer to be word-aligned.
-
INTRODUCTION TO FORMS DESIGN USING FORMSPEC TO CREATE AN ARB :RUN ARBPROG Field 1 : Buffer offset from 0 = 1 Length = 2 Type = INT Value = 1234 Field 2 : Buffer offset from 0 = 3 Length = 2 Type = INT Value = 1234 Field 3 : Buffer offset from 0 = 6 Length = 2 Type = INT Value = 1234 Field 4 : Buffer offset from 0 = 9 Length = 4 Type = DINT Value = 12345678 Field 5 : Buffer offset from 0 = 14 Length = 4 Type = DINT Value = -1234567 Field 6 : Buffer offset from 0 = 19 Length = 4 Type = DINT Value =
-
INTRODUCTION TO FORMS DESIGN TERMINAL/LANGUAGE SELECTION MENU TERMINAL/LANGUAGE SELECTION MENU The Terminal/Language Selection Menu allows you to specify which terminals will be used with the forms file. You may select one family or any combination of families, including all four families (HP 264X, HP 262X, HP 239X (includes HP 150), and HP 307X). The HP 264X family is the terminal default value.
-
INTRODUCTION TO FORMS DESIGN TERMINAL/LANGUAGE SELECTION MENU HP262X, HP239X Families Specify an X for HP 262X and HP 239X terminals; includes HP 150 terminals. HP3075A, HP3076A, HP3081A Specify an X in the HP 3075A, HP 3076A, HP 3081A box in order for the forms file to run on the data capture devices; specify an 8 to run on the data capture devices and take full advantage of the HP 3081A.
-
INTRODUCTION TO FORMS DESIGN DATA CAPTURE DEVICE SPECIFICATIONS MENU DATA CAPTURE DEVICE SPECIFICATIONS MENU If you select the data capture devices on the Terminal/Language Selection Menu, the following message will appear at the bottom of the Globals Menu: Press NEXT to select HP 3075/6 device specifications Press NEXT to display the Data Capture (3075/6) Device Specifications Menu, as shown in Figure 3-32.
-
INTRODUCTION TO FORMS DESIGN DATA CAPTURE DEVICE SPECIFICATIONS MENU OR Wait for user to press ENTER You may also specify that screen presentations for messages longer than 24 (or 32) characters be displayed after ENTER is pressed. Enter a YES in this box and a zero (0) in the Split Message Pause box. This field does not apply to Mini-CRT display. Default NO Error Light You may specify which keyboard light is to be lit if an error is detected on the form by the application or by VPLUS.
-
INTRODUCTION TO FORMS DESIGN DATA CAPTURE DEVICE SPECIFICATIONS MENU digits. You can change this by specifying yes (Y) in this field. Default N Example of how a typical form layout will took displayed on the data capture devices: Figure 3-33. Form Layout in FORMSPEC This is the first line of the form. This is line 3 of the form and it extends all the way to column 80..... This line starts in column 17. This line starts in column 25. This line starts in column 33. Figure 3-34.
-
INTRODUCTION TO FORMS DESIGN DATA CAPTURE DEVICE SPECIFICATIONS MENU Figure 3-36. Displayed on Large Character Mini-CRT Screen This is the first line of the form. This is line 3 of the form and it extends all the way to column 80 ..........
-
Advanced Forms Design 4 Advanced Forms Design The processing specifications for advanced forms design allow you to: • Compare a field value to a specified single value, range of values, list of values, or a pattern. • Test a check digit. • Specify up to 20 global save fields. • Assign a value to any field in the form, including save fields. • Move values between fields in a form or, using save fields, between fields in different forms. • Perform arithmetic calculations on data in numeric fields.
-
Advanced Forms Design Levels Of Advanced Design Levels Of Advanced Design Advanced forms design can be separated into two levels of processing specifications: • Field Edits — use a comprehensive set of editing statements that apply to a single field. These statements allow you to test a value entered in a field for length, and to compare the value to a single value, a range of values, the values in a table or against a pattern, and to test a check digit in a field.
-
Advanced Forms Design Entering Processing Specifications Entering Processing Specifications After defining the field attributes on the Field Menu (as described in Section 3), if you want to define additional processing, press FIELD TOGGLE. You can then enter the processing statements in the lower (nonformatted) area of the Field Menu. (Refer to Figure 4-1. for an illustration of the Field Menu that includes processing specifications.
-
Advanced Forms Design Entering Processing Specifications Special Cases If a processing specification statement line extends to the 80th column, the line is expanded to two lines when you return to the Field Menu. This may in turn result in processing specification truncation due to either terminal memory overflow or FORMSPEC internal buffer overflow. In nonformatted mode, it is possible to accidentally clear or delete any field attributes with a key such as CLEAR DISPLAY or DELETE LINE.
-
Advanced Forms Design Statement Syntax Statement Syntax The processing specifications consist of statement names followed by parameters. The description of each statement uses the conventions defined at the beginning of the manual. In order to understand the notation used in the statement formats in this section, you should review these conventions. Multiple statements can be placed on the same line by following the last parameter of the statement by a blank and the next statement.
-
Advanced Forms Design Statement Syntax Figure 4-2. Field Menu with Custom Error Messages Checking Data Entered The field attributes for the field determine the first checks made on the data in the field. For example, if the field is required (FType=R), it is checked to be sure that the user has entered a value in the field. Editing is performed according to the data type. For example, if the data type is DIG, then the field is checked to be sure that only the digits 0-9 were entered in the field.
-
Advanced Forms Design Statement Syntax CONFIGuration Statements LOCALEDITS [ALPHABETIC ALPHANUMERIC CONSTANT IMP_DEC IMP_DEC_FILL INTEGER INTEGER_FILL SIGN_DEC SIGN_DEC_FILL UNRESTRICTED UPSHIFT ] [JUSTIFY MUST_FILL REQUIRED] ...[DEC_DIGITS n] [DEC_TYPE_EUR DEC_TYPE_US ] [TRANSMIT_ONLY] LIGHT {@ A ... O P }... DEVICE {PRINTER KEYBOARD MAGSTRIPE TYPEV MULTIFUNCTION READER MFR [CADMARKS NONE HOLES CAD HOLES [CUT NOCUT]] DISPLAY [LARGECHAR STDCHAR] BARCODE [READER] [UPC I25 I39 MAT EAN IVL]}...
-
Advanced Forms Design Statement Syntax Edit Statements MINLEN value [“msg”] {GT LT GE LE EQ NE} value [“msg”] {IN NIN} { value[,value] lowvalue:highvalue[,lowvalue:highvalue]... value[,lowvalue:highvalue]... } [“msg”] MATCH pattern [“msg”] CDIGIT {10 11} [“msg”] Formatting Statements STRIP FILL { TRAILING LEADING ALL } “character” {LEADING TRAILING } “character” JUSTIFY { LEFT RIGHT CENTER} UPSHIFT SET Statements SET { TO { value index OF value[,value]...
-
Advanced Forms Design Statement Syntax Conditional Statement IF [ value] editstatement THEN [statement]... [statement]... [ELSE [statement]... [statement]... Control Statement FAIL [“msg”] STOP Operands Whenever value is specified as an operand in a field processing statement, a field name, constant, expression, or a save field name can be used. If the operand is numeric, any of these can be combined into an arithmetic expression whose result is used as the operand.
-
Advanced Forms Design Statement Syntax Character Character constants are strings of any character enclosed in single or double quotes. For example: "This is a constant." 'and this is, too!' $EMPTY $STATE Numeric Numeric constants are digit strings with an optional leading sign and optional decimal point. Commas are not allowed in numeric constants. If the constant has no decimal point, a decimal is assumed at the right of the rightmost (least significant) digit.
-
Advanced Forms Design Statement Syntax parentheses are evaluated first and, if parentheses are nested, the innermost are evaluated first. The % in the expression a%b is equivalent to (a*.01)*b. When $EMPTY is used in an arithmetic expression, the result is always $EMPTY. Thus, $EMPTY with any operator and operand = $EMPTY. The following examples illustrate arithmetic expressions: F2 + 1 Add 1 to the value in field F2. QUANTITY * UNITPRICE Multiply value in QUANTITY by value in UNITPRICE.
-
Advanced Forms Design Statement Syntax 4, the selected operand is 25. Parentheses are not required in a SET statement. CHANGE NFORM TO X OF "FORMA", "FORMB", "FORMC", OPSELECT X may be a value between 1 and 4. If its value is 4, the field name OPSELECT is chosen. The value of OPSELECT must be type character to conform to the other elements in the list, and to make sense it should contain a form name. No parentheses are needed in a CHANGE statement.
-
Advanced Forms Design Processing Specifications For Configuration Processing Specifications For Configuration You can use the processing specifications for configuration to specify local editing to be done on the HP 2394A and HP 2624A/B terminal, and to specify the input device and prompting lights for use on the data capture devices. These statements may only be used in the configuration phase of field processing, and must have the CONFIG heading in the processing specification area of the Field Menu.
-
Advanced Forms Design DEVICE DEVICE Enables the input media device on a data capture device. Syntax DEVICE {device1,device2,...devicen} Parameters device Any of the following may be specified: PRINTER KEYBOARD MAGSTRIPE TYPEV MULTIFUNCTION READER DISPLAY BARCODE READER There are no default devices. Note that MULTIFUNCTION READER and BARCODE READER must be abbreviated as MFR and BARCODE respectively.
-
Advanced Forms Design LIGHT LIGHT Specifies which light will be lit during field presentation on a data capture device. Syntax LIGHT {light1,light2,...lightn} Parameters light Specifying @ turns on the light associated with the shift key. The remaining valid characters of A through P are associated with the same characters on the alphanumeric keyboard. Discussion This command allows you to specify which, if any, of the seventeen available prompting lights is to be turned on during a field presentation.
-
Advanced Forms Design LOCALEDITS LOCALEDITS Used to stipulate edits to be done within the terminal. Syntax LOCALEDITS {edit1,edit2,...editn} Parameters edit Table 4-2. lists available local edits along with their meanings. Refer to Table 4-1. for valid local edit combinations. For example, you can specify alphanumeric, required, decimal type, and number of digits to the right of the decimal together. You cannot specify alphanumeric and upshift together.
-
Advanced Forms Design LOCALEDITS Table 4-1. Summary of Processing Statements Local Edit Description ALPHABETIC Upper and lowercase alphabetic, space, period, hyphen ALPHANUMERIC Upper and lowercase alphabetic, digits, space, period, minus sign, plus sign, comma. CONSTANT No characters may be entered from the keyboard, IMP_DEC Implied decimal (the number of digits to the right of the decimal is governed by the last DEC_DIGITS command in the form).
-
Advanced Forms Design LOCALEDITS Here is a table showing the local edit terminal menu selection and associated VPLUS local edits. Table 4-2. Local Edit Terminal Menu Selection Local Edit Terminal Menu Selection Justify is used UNRESTRICTED 0. ALL CHARACTERS Left Justify ALPHABETIC 1. ALPHABETIC Left Justify UPSHIFT 2. AUTO UPSHIFT Left Justify ALPHANUMERIC 3. ALPHANUMERIC Left Justify INTEGER 4. INTEGER right justify SIGN_DEC 5. SIGNED DECIMAL right justify IMP_DEC 6.
-
Advanced Forms Design LOCALEDITS Table 4-4. Local Edit Terminal Menu Items Local Edit Terminal Menu Item Menu Selection DEC_DIGITS n Implied Dec digits 0-9 DEC_TYPE_EUR Decimal Type EUR DEC_TYPE_US Decimal Type US Along with the selections from Table 4-2. and Table 4-3. you may specify the number of decimal digits (DEC_DIGITS n) and select a decimal format (DEC_TYPE_US or DEC_TYPE_EUR). (Note that the DEC_DIGITS n setting may only be used with IMP_DEC or IMP_DEC_FILL edits.
-
Advanced Forms Design Processing Specifications For Field Edits Processing Specifications For Field Edits If only field editing is needed, the edit statements listed below provide full field edits. Edit statements apply to the current field only. During table and range checks leading and trailing blanks are stripped. (The current field is the field defined in the Field Menu in which the edit statements are specified.
-
Advanced Forms Design LENGTH CHECK LENGTH CHECK Used to specify the minimum length of a field value. Syntax MINLEN value ["message"] Parameters value The value can be a field, constant, save field, or a numeric expression, or it may be an index retrieve operand within parentheses. Refer to "Statement Syntax" earlier in this section for details. message Specifies a custom error message.
-
Advanced Forms Design SINGLE VALUE COMPARISONS SINGLE VALUE COMPARISONS Used to compare the field value against a single value. Syntax [{GT LT GE LE EQ NE} value [“message”]] Parameters value The value can be a field, constant, save field, or a numeric expression, or it may be an index retrieve operand within parentheses. Refer to "Statement Syntax" earlier in this section for details. message Specifies a custom error message.
-
Advanced Forms Design SINGLE VALUE COMPARISONS Numeric Comparisons When numeric values are compared, they are first converted to the HP 3000 internal representation of the number. Thus, a field of type IMPn can be compared with NUMn, and NUMn or IMPn fields can be compared to type DIG fields. For example, assume a field of type NUM 2 in which the value 123 has been entered.
-
Advanced Forms Design TABLE CHECKS TABLE CHECKS Used to verify that the field value is either in a list (table) of values, or is not in that list. Syntax [{IN NIN} value1[,value2]...[“message”]] Parameters value The values specified in the list may be any mixture of field names, save fields, constants, numeric expressions, or it may be an index retrieve operand within parentheses. Refer to "Statement Syntax" earlier in this section for details. message Specifies a custom error message.
-
Advanced Forms Design RANGE CHECKS RANGE CHECKS Used to check whether the field value is within, or is not within, a specified range of values. Syntax [{IN NIN} lowvalue:highvalue [,lowvalue:highvalue]… ["message"]] Parameters value The value can be a field, constant, save field, or a numeric expression, or it may be an index retrieve operand within parentheses. message Specifies a custom error message.
-
Advanced Forms Design RANGE CHECKS IN "ADE": "BB", "s", "t" The field may have any value in the range ADE through BB or it can be s or t. Thus, it could be Abcd, or B or t, but it cannot be AB or S. In NATIVE-3000, all lowercase letters are greater than any uppercase letters. IN "20":"30" Allows any character values between 20 and 30 in the USASCII collating sequence. Thus 2A and 3& are valid for NATIVE-3000. (Other native languages use other collating sequences.
-
Advanced Forms Design CHECK DIGIT CHECK DIGIT Used to test the check digit in a numeric or alphanumeric field (modulus 10 or 11). Syntax [CDIGIT {11 10} ["message"]] Parameters message Specifies a custom error message. Discussion Check digit verification is a special check on a numeric or alphanumeric field in which the last (rightmost) character is a check digit. Verification can be either modulus 10 or modulus 11.
-
Advanced Forms Design PATTERN MATCH PATTERN MATCH Used to test a field value against a pattern of characters. Syntax MATCH pattern ["message"] Parameters pattern A pattern of characters which indicate which type of character in which position is acceptable input for this field. message Specifies a custom error message. Discussion The pattern match allows you to check field values against a general pattern.
-
Advanced Forms Design PATTERN MATCH pattern can span more than one line if it is enclosed within braces {}. If a pattern is within braces, it is terminated by the first blank outside the braces. The match pattern can include specific characters in addition to the types listed above. To illustrate: MATCH Aaa-ddd This pattern means that the value must start with the letter A, be followed by any two upper or lowercase letters of the alphabet, followed by a hyphen and then three digits.
-
Advanced Forms Design PATTERN MATCH pattern. MATCH !a:f Since the letter a is a pattern character, it is preceded by an exclamation point. Other such characters within the range are implicitly preceded by this operator. Thus, the range is equivalent to specifying MATCH !a,!b,c,!d,e,f. It is important to differentiate between a pattern range which is a range of single characters, and the range check described earlier.
-
Advanced Forms Design PATTERN MATCH optional, in which case a blank is accepted because processing specifications are ignored. For example, 2 or 7654321 or 55 are acceptable. MATCH Xd+ This pattern accepts the letter X followed by one or more digits. For example, X1 or X2345, and so forth are acceptable, but not X. MATCH M{A,C,d}+ A plus sign after a pair of braces indicates repetition of any item within the braces, in any order. Some acceptable values are MA, MCCC, or M12333CAA9.
-
Advanced Forms Design PATTERN MATCH Table 4-5. Pattern Match Operators Operator Function Example Exclamation point ! Transparency operator that allows use of any special MATCH characters as an element in the pattern. MATCH !u,!d,!,, accepts any of the values u, d,,, or !. Comma , Choice of subpatterns, any one of which satisfies the match. MATCH A,B, dd accepts values such as A,B, and 22. Colon: Range of single characters in ascending collating order, any one of which satisfies the match.
-
Advanced Forms Design Processing Specifications For Advanced Processing Processing Specifications For Advanced Processing The advanced processing discussed in the rest of this section includes: • Data movement. Data movement falls into two basic categories: setting the current field to a value and moving data between fields. Each of these categories uses the SET statement. • Data formatting. When data is moved between fields with the SET statement, certain automatic formatting is performed.
-
Advanced Forms Design SET SET Used to move data either by setting the current field to a value or by moving data between fields. Also performs automatic formatting. Syntax [SET {destination TO source destination TO source}] Parameters source Can be a field name, save field name, constant, arithmetic expression, or an index retrieve operand within parenthesis. Refer to "Statement Syntax" earlier in this section for details. destination Can be a field name or save field name.
-
Advanced Forms Design SET value (see Table 4-7.). By default, all fields are initialized to blanks in the initialization phase (refer to "Phases" at end of this section for more information on phases.) You can specify a particular initial value for any field by including an initial value in the Field Menu field attributes. More elaborate initialization can be done with this subset of the SET statement. When you assign an initial value to a field in the Field Menu, you can specify only a constant.
-
Advanced Forms Design SET Syntax [SET {destination destination ''TO'' source}] Parameters source Can be a field name, save field name, constant, arithmetic expression, or an index retrieve operand within parenthesis. Refer to "Statement Syntax" earlier in this section for details. destination Can be a field name or save field name. Discussion When a source is not included, whatever value is in the current field is moved to the specified destination.
-
Advanced Forms Design SET Table 4-6. Automatic Formatting for Character Data Source Destination "ARMSTRONG" (9 characters) "ARMSTRONG∆" (10 characters) "∆∆ARMSTRONG" (11 characters) "∆∆ARMSTRON" (10 characters) "ARMSTRONG∆∆∆∆∆" (14 characters) "ARMSTRONG" (9 characters) Numeric Type When data is moved between numeric fields, the following formatting is performed: Sign Any plus sign is stripped from the source before the number is moved to its destination.
-
Advanced Forms Design SET Table 4-7. Automatic Formatting for Numeric Data Source Destination 123 (DIG) 123 (DIGIT,length is 5) 123 (IMP2) 1.23 (NUM2,length is 4) 12.3 (NUM1) 12.3 (NUM,length is 6) 12.3 (NUM1) 12.30 (NUM2)length is 5) 12.3 (NUM1) 12. (NUM2,length is 3) 12.3 (NUM1) 1230 (IMP2,length is 4) 12.3 (NUM1) 123 (IMP1,length is 3) +3357 (NUM) 335700 (IMP2,length is 6) -3357 (IMP3) -3.4 (NUM1,length is 4) 001,000 (NUM) 1000.
-
Advanced Forms Design SET Table 4-9.
-
Advanced Forms Design SET Figure 4-3. Field Menu with a SET Statement Example 1. Suppose the user enters a price in the field as follows: [123.5∆∆∆∆] The SET statement causes it to be formatted as: [∆∆∆123.50] 2. In another situation, this version of SET TO can be used to format a date.
-
Advanced Forms Design STRIP STRIP Used to delete any specified character in the field. Syntax [STRIP {TRAILING LEADING ALL} "characters"] Parameters TRAILING If TRAILING is specified, all occurrences of each character at the end of the field are replaced with blanks. LEADING STRIP LEADING replaces with blanks all occurrences of each character at the beginning of the field. ALL STRIP ALL deletes all occurrences of each character, compressing the data to the left.
-
Advanced Forms Design JUSTIFY JUSTIFY Used to move data within a field to the left or right boundary of the field, or center it within the field. Syntax [JUSTIFY {LEFT RIGHT CENTER}] Parameters LEFT The data in the current field is shifted to the left. RIGHT The data in the current field is shifted to the right. CENTER The data in the current field is centered in the field. Discussion The JUSTIFY statement can be used to format data entered into or moved to any field.
-
Advanced Forms Design FILL FILL Used to replace all the blanks between the field boundaries and the first or last nonblank data character with a designated character. Syntax [FILL {TRAILING LEADING } "character"] Parameters TRAILING FILL TRAILING replaces those blanks following the data with the specified character. LEADING FILL LEADING replaces the blanks preceding the data with the specified character. character The specified character is any single character.
-
Advanced Forms Design UPSHIFT UPSHIFT Used to shift every lowercase character in a field to its uppercase equivalent. Syntax UPSHIFT Discussion The UPSHIFT statement can be used to format data entered into or moved to any field. (For automatic formatting, refer to the SET command earlier in this section.) This statement causes all alphabetic characters to be replaced with their uppercase counterparts.
-
Advanced Forms Design CHANGE CHANGE Used to change the specification of either the current form or the next form. Syntax [CHANGE NFORM TO {[CLEAR APPEND FREEZE APPEND] ["formname" fieldname indexretrieve $RETURN $HEAD$END $REFRESH CHANGE CFORM TO {NOREPEAT REPEAT REPEAT APPEND}] ]} Parameters NFORM indicates the next form to be displayed after the current form at execution time. CFORM indicates the current form. CLEAR indicates that the screen is to be cleared when the next form is displayed.
-
Advanced Forms Design CHANGE field or save field whose value is a form name. The name must identify an existing form. $RETURN indicates the last different form displayed before the current form at execution time. $HEAD indicates the first form displayed at execution time. $END indicates to ENTRY or an application that the current form is the last form to be displayed. $REFRESH indicates that current form is to be refreshed (cleared of entered data) and displayed as the next form.
-
Advanced Forms Design IF IF Used to execute any of the processing statements only under certain conditions. Syntax [IF condition THEN [statement] [statement] . . . [statement] [ELSE [statement] [statement ]. . . [statement]]] where condition is: [{ constant field save field expression (indexretrieve) } editstatement] Parameters condition A condition specified in an IF statement can be any edit statement described below.
-
Advanced Forms Design IF Discussion An IF statement consists of two groups of statements: the THEN part and the ELSE part. Either may have no statements associated with it. The THEN part may include statements on the same line as THEN, plus statements indented from the IF on immediately following lines. An ELSE statement at the same level of indentation as the IF corresponds to that IF.
-
Advanced Forms Design IF Table 4-10. Variations on the IF Statement Variation Description IF condition THEN statement Simple IF statement. If condition is true, then statement is executed; if false, then statement is not executed. IF condition THEN statement statement statement If condition is true, all three statements are executed in the order specified. If condition is false, none of the three statements is executed.
-
Advanced Forms Design FAIL FAIL Used to force failure of a field edit. Syntax [FAIL ["message"]] Parameters message Specifies a custom error message. Discussion When this statement is executed, it forces data entered in the current field to fail any specified edits. When FAIL is executed, an error flag is set for the field. If you include the message parameter, that message is issued; otherwise, a system message is issued.
-
Advanced Forms Design STOP STOP Used to stop processing the current phase of the current form. Syntax [STOP] Discussion When STOP is executed, no further processing is performed on the current field, or on any subsequent fields in the form in this phase.
-
Advanced Forms Design PHASES PHASES Used to determine when specified processing specifications are executed. Syntax phaseheader [statement] . . . [statement] Parameters phaseheader One of the following headings. The phase headings must be specified in the order shown: CONFIG Perform the following configuration during form presentation. INIT Perform the following statements during initialization (VINITFORM). FIELD Perform the following statements during the field edit phase (VFIELDEDITS).
-
Advanced Forms Design PHASES specification statements. It is important to note that while specifications are entered field by field, execution of the phases applies to the entire form. If you omit these phase headings altogether, all statements are executed in the field edit phase. Example CONFIG LOCALEDITS alphabetic LIGHTB DEVICE printer INIT SET TO 20.
-
Advanced Forms Design PHASES Figure 4-4.
-
Advanced Forms Design PHASES Field Edit Phase The field edit phase occurs when VFIELDEDITS is called. The field edit phase is usually requested by the application after the form is displayed on the screen, and the user has input data. During this phase, the entered data is checked according to the field attributes and any processing specifications entered by the designer. The Edit statements can be executed only in the field edit phase. Each field in turn is examined.
-
Advanced Forms Design PHASES 180 Chapter 4
-
Reformatting Specifications 5 Reformatting Specifications Information gathered during data collection is stored in one or more "batch" files. The data entered for each field in a form is stored exactly as it was entered. All blanks, punctuation, or special characters are included in the data. The only exception is that any formatting specified on the Field Menu or any automatic formatting resulting from data movement (refer to Chapter 4) is completed before the data is written to the batch file.
-
Reformatting Specifications Figure 5-1.
-
Reformatting Specifications Files Files One batch file containing collected data can be reformatted into one output file. This output file is then used as input to the application that processes the collected data. Data from more than one batch file can be written to one output file in sequence — that is, data from a batch file can be appended to data from another batch file in an existing output file with an MPE :FILE command equation.
-
Reformatting Specifications Files Figure 5-2. Prototype of REFORMAT File REFORMAT FILE Forms File Name Global specifications that apply to all reformats in reformat file.
-
Reformatting Specifications Relation of Forms to Output Records Relation of Forms to Output Records Every record in a batch file consists of data entered on a single form. It may be that the data on one form represents a logical group of information. However, the data from a sequence of forms may make up such a logical grouping, or the data entered on one form may make several logical groupings. The reformatter allows you to rearrange the entered data into output records with different groupings.
-
Reformatting Specifications Relation of Forms to Output Records records starting with the reformat identifier must exactly match the sequence of forms. Output Record Definition The output record definition determines how information from batch file records is stored in the output file. Any field in the batch file that is to be written to an output record must be uniquely identified.
-
Reformatting Specifications Relation of Forms to Output Records Field Specifications An Output Field Menu is issued for each field named in the preceding output record definition. The designer can reformat the output field, or leave the field as it was written to the batch file. The following set of examples illustrates some ways in which the data from a batch file can be reorganized in an output file. Combining Data from Several Forms Suppose data is entered on forms A, B, and C.
-
Reformatting Specifications Relation of Forms to Output Records Data from the batch file illustrated in Figure 5-3. can be reformatted in many different ways. For example, Figure 5-4. shows how this same data could be combined into two output records with data from forms A and B appearing in both records. Note that when the same field appears more than once, it must be given a unique field name for each occurrence (this is not specifically shown in Figure 5-4.) Figure 5-4.
-
Reformatting Specifications Relation of Forms to Output Records Separating Data into Several Records In the following example, Figure 5-5., data entered on form A is separated into three output records, each a fixed length of 40 bytes. Data from a subsequent form is written to a single 40-byte record. If any group of data is less than the 40-byte record length, the record is padded with blanks. The data cannot be formatted to exceed the record length. Figure 5-5.
-
Reformatting Specifications Relation of Forms to Output Records single variable length output record. Note that if repeating form B causes so much data to be written to the output record that the maximum record length is exceeded, data (possibly significant) is truncated when REFORMAT is run. Figure 5-6. Reformatting Data from Repeating Forms REFORMAT FILE BATCH FILE OUTPUT FILE rec # GLOBALS INPUT FORMS SEQ form A OUTPUT REC. DEF field 1 form A* 1 OUTPUT FIELD F10A INPUT FORMS SEQ. form B OUTPUT REC.
-
Reformatting Specifications Relation of Forms to Output Records Suppose data entered on one form can follow data entered on either of two different forms, and you want to generate separate records depending on the sequence in which the forms appear. In such a case, you can set up a reformat file as shown in Figure 5-7. Note that form B (a repeating form) appears as a reformat identifier and also as a succeeding form in other input forms sequences. Figure 5-7.
-
Reformatting Specifications Relation of Forms to Output Records Separating Data from One Batch File into Several Output Files A separate reformat file must be established for each different output file. In Figure 5-8., data entered on forms A and B is written as a single record to one output file. Data from forms A and C is written as two records to a second output file; data from form B is not written to output file 2. Figure 5-8.
-
Reformatting Specifications Using REFSPEC Using REFSPEC You execute REFSPEC by entering the following command in response to the MPE colon prompt: :RUN REFSPEC.PUB.SYS Since REFSPEC runs entirely in block mode, your terminal is placed in block mode automatically. Like FORMSPEC, REFSPEC prompts for information on menu screens. The information you enter on these menus defines how data in the batch file is to be reformatted and written to an output file.
-
Reformatting Specifications Using REFSPEC REFSPEC Function Keys A set of seven function keys, similar to those used for forms design, are used to control execution of REFSPEC. These keys are described in Table 5-1. Table 5-1. Key Definitions Key Key Action PREV FORMAT f1 Go to previous Input Forms Menu (skipping any intervening menus). NEXT FORMAT f2 Go to next Input Forms Menu (skipping any intervening menus). Not defined.
-
Reformatting Specifications REFSPEC Menus REFSPEC Menus REFSPEC displays menu screens in a predetermined sequence. As each menu is displayed, enter the reformatting specifications you want in the reformat file, and then press ENTER. When ENTER is pressed, the specifications are written to the reformat file and the next menu in the sequence is issued. If you do not want to enter any specifications (on a menu such as the Globals Menu where defaults are supplied), simply press NEXT to display the next menu.
-
Reformatting Specifications REFSPEC Menus Figure 5-9.
-
Reformatting Specifications Forms File Menu Forms File Menu The Forms File Menu, shown in Figure 5-10., asks you to enter the name of an existing forms file. This is the file that was used to create the batch file (or files) to be reformatted. Only one forms file can be specified for each reformat file. The name of the data file may be a fully qualified MPE file name. After you have identified the forms file, the Main Menu is issued.
-
Reformatting Specifications Main Menu Main Menu The Main Menu, shown in Figure 5-11., is the main control menu for all REFSPEC operations. If the reformat file is new, you will usually select Add a reformat. REFSPEC then issues the menus that allow you to define the reformat file. If the reformat file already exists, you may enter any selection depending on what you want to do.
-
Reformatting Specifications Main Menu If the file has already been compiled, it is recompiled and the newly compiled version replaces the previous version. There is never more than one compiled version of a reformat file at a time. When you modify the source version, the compiled version is not affected. Adding Global Specifications Certain characteristics of the reformat definition are global; that is, they apply to the entire output file.
-
Reformatting Specifications Main Menu appropriate changes before pressing ENTER.) Until these menus are validated, REFSPEC prints a warning when they are displayed. Changing an Output Record Definition Every input forms sequence has an associated output record definition. The output record definition defines how the individual fields or portions of fields from the batch file are to be written to the output file.
-
Reformatting Specifications Main Menu Figure 5-12. Reformat Listing ******************************************************************************* * REFSPEC Version v.uu.ff * * MON, JUN 16. 1986, 5:24 PM * * * * REF211.PUB.ACCTG * * * ************************************************************************* Reformat File Status Modified: TUE, DEC 31, 1985, 9:45 AM Compiled: TUE, DEC 31, 1985, 9:45 AM Forms File: FORMS32.PUB.
-
Reformatting Specifications Main Menu Figure 5-13. Reformat Listing (Continued) REFSPEC VERSION v.uu.ff MON, JUN 16, 1986, 5:24 AM REFORMAT FILE: REF211.PUB.ACCTG INPUT Field: FIELD1 OUTPUT Field: fIELD 1 Start: 1 Length: 6 Start: 1 Length: STRIP: All: CHECK DIGIT: JUSTIFY: SIGN: FILL: All: Leading: 6 Form: FORM211 Data Type: CHAR Trailing: PLUS SIGN? Leading: Trailing: . .
-
Reformatting Specifications Globals Menu Globals Menu The Globals Menu, shown in Figure 5-13., requests information that applies to the total reformat process. All information entered on the Globals Menu relates to the output file produced when REFORMAT is run. Since only one output file is generated for each REFORMAT execution, this information appears only once in the reformat file. Figure 5-13. Globals Menu FORMSPEC v.uu.
-
Reformatting Specifications Globals Menu Record Length A positive integer that specifies the total number of characters in the output record, including all fields and separators. If the output records are fixed length and the total number of characters is less than this length, the record is padded with blanks at the end. If there are more characters in the field than will fit in the record, the record is written up to the specified length and the excess characters are discarded.
-
Reformatting Specifications Globals Menu — $US — unit separator — $RS — record separator Default = No terminator If a record terminator is not specified, no special terminator is placed at the end of output records. You can combine any of the above terminators into a single terminator by specifying them one after the other. For example: "end" $LF $CR or $120 "! " $CR or "ABC" "DEF". Such multiple terminators are concatenated together to form a single string that is inserted between fields.
-
Reformatting Specifications Input Forms Menu Input Forms Menu The Input Forms Menu, shown in Figure 5-14., is used to specify one or more forms whose data is to be written to the output file. You can specify as many input forms sequences as there are forms in the forms file, or you can specify as few as one input forms sequence. Each input forms sequence may contain a single form name or it may contain up to 10 form names. The first form in the sequence (or the only form) is the reformat identifier.
-
Reformatting Specifications Input Forms Menu included with the data in the batch file.) To illustrate, assume the following input forms sequence: FORMA (reformat identifier) FORMB FORMD And assume the first three records of data in the batch file were entered on forms in the sequence: FORMA FORMB FORMC The data entered on FORMA of this sequence will not be written to the output file.
-
Reformatting Specifications Output Record Menu Output Record Menu An Output Record Menu, shown in Figure 5-15., is issued for every input forms sequence. It specifies which fields in the input forms are to be written to an output record. The output record definition may generate one output record, many output records, or only a portion of an output record. The order in which fields are specified is the order in which they are written to the output record. The Output Record Menu is not a true menu screen.
-
Reformatting Specifications Output Record Menu Figure 5-16. Sample Output Record Menu FORMSPEC v.uu.ff Output Record Menu REFORMAT IDENTIFIER: A INPUT Field Name “ship to:” NAME ADDR ADDR ZIP $RS Substring Strt Len NEXT FORM Form Name Field Name Strt Col Len Strt Rec * 1 21 “Account Number:” ACCTNO $RS - PREV FORM OUTPUT 20 30 FORMA FORMA FORMA FORMA ADDR1 FORMA ACCTB REFRESH PREV NEXT * MAIN/ RESUME EXIT When the output record definition has been defined, press ENTER.
-
Reformatting Specifications Output Record Menu Fields Field Name (Required) Identifies the field in the batch file to be written to the output file. The field name must identify an existing field in one of the forms specified in the preceding input sequence. The field name need not be unique to the output definition. But, if it is not unique, a different output field name must be entered for each identical input field name.
-
Reformatting Specifications Output Record Menu Strt Col (Optional) If you want the field to start in a particular column in the output record rather than immediately after the preceding field, you can specify a starting column. Column numbers in this case correspond to character (byte) positions in the output record. Columns are numbered starting with 1. When you specify a new starting column, REFSPEC checks to make sure the starting column does not overwrite a previous field in the output record.
-
Reformatting Specifications Output Record Menu — — — — $LF line feed $GS group separator $US unit separator $RS record separator The following are acceptable constants: "Part No." 'ABC' $65 $34"NAME"$34 $RS Constants may not be specified on the same line as a field name. More than one constant can be specified on a line. When multiple constants are specified, they are concatenated into a single literal value. For example: "Part No." $GS $65.
-
Reformatting Specifications Output Field Menu Output Field Menu A separate Output Field Menu shown in Figure 5-17., is displayed for every input field named in the preceding Output Record Menu. The Output Field Menus are issued in the order the field names were entered in the output record definition. No Output Field Menu is issued for constants. The Output Field Menu displays the information for a field entered on the preceding output record definition.
-
Reformatting Specifications Output Field Menu by data type.) The remaining items in the Output Field Menu allow you to specify reformatting to be performed on the data item when it is moved to the output field. Note that these reformatting specifications cannot override the standard conversion and reformatting performed on the item based on the destination data type. Data Type You may change the output data type to a type other than CHAR.
-
Reformatting Specifications Output Field Menu than CHAR. Table 5-2. Standard Formatting by Data Types Destination Data Type Standard Formatting CHAR Conversion: none. Data movement: Move data to output field, character by character from leftmost character (including blanks) through last character (including blanks). If the data is shorter than the output field, pad with blanks on the right. If the data is longer than the output field, truncate on the right.
-
Reformatting Specifications Output Field Menu Table 5-2. Standard Formatting by Data Types Destination Data Type Standard Formatting NUMn\or \NUM Conversion and Movement: Strip any commas, sign, or leading zeros. Float any minus sign to position preceding the first nonblank character. Right justify data in the output field. If the data is shorter than the field, pad with blanks on the left. If the data is too long, strip leading blanks one at a time until data fits.
-
Reformatting Specifications Output Field Menu REFSPEC performs all formatting (user-defined and standard) in the following order: 1. Convert data to destination data type (unless type is CHAR). If numeric type data does not fit in the output field after conversion, the output field is set to all blanks, 2. STRIP (user-specified) 3. Move data to output field, justified left, and inserting check digit if specified, and padding with blanks as needed.
-
Reformatting Specifications Output Field Menu Table 5-3. Examples Using STRIP Data Type Input Value Specification Output Value CHAR ∆ACBAXCBYZBB none STRIP ALL "ABC" STRIP LEADING "ABC" STRIP TRAILING "ABC" ∆ACBAXCBYZBB ∆XYZ∆∆∆∆∆∆∆∆ ∆∆∆∆∆XCBYZBB ∆ACBAXCBYZ∆∆ DIGIT ∆234567∆∆∆∆ none STRIP ALL "35" STRIP LEADING "0" STRIP TRAILING "7" ∆∆∆∆∆1234567 ∆∆∆∆∆12467∆∆∆ ∆∆∆∆∆12345.67 ∆∆∆∆∆3456∆ NUM2 ∆12,345.67∆∆ none STRIP ALL "35" STRIP LEADING "01" STRIP TRAILING "7" ∆∆∆-12345.67 ∆∆∆-124.
-
Reformatting Specifications Output Field Menu types are the same. Table 5-4.
-
Reformatting Specifications Output Field Menu Table 5-5. Correspondence Between Signed Digits and Characters Positive Values Positive Values Negative Values Negative Values Signed Digit Character Signed Digit Character +0 { -0 } +1 A -1 J +2 B -2 K +3 C -3 L +4 D -4 M +5 E -5 N +6 F -6 O +7 G -7 P +8 H -8 Q +9 I -9 R In Table 5-6. are examples that illustrate the use of the SIGN option. The input and output fields are assumed to be the same data type.
-
Reformatting Specifications Output Field Menu Default = none You can specify both FILL LEADING and FILL TRAILING with no redundancy. But, you must not specify either FILL LEADING or FILL TRAILING with FILL ALL. Since the FILL ALL fills all the blanks, any other FILL specification for the field is diagnosed as an error. The examples in Table 5-7. illustrate use of the FILL option. The input and output data types are the same. Table 5-7.
-
Reformatting Specifications Output Field Menu 10 or modulo 11 is specified. Examples: CHECKDIGIT 10 Calculate check digit according to modulo 10 formula and add it following rightmost nonblank digit. CHECKDIGIT 11 Calculate check digit according to modulo 11 formula and add it following rightmost nonblank digit.
-
Reformatting Specifications Running REFORMAT Running REFORMAT Once the reformat specifications have been defined and are stored in a compiled reformat file, you can run REFORMAT to actually reformat the data in the batch file and write it to the output file. REFORMAT is not an interactive program. That is, it does not prompt for any information. It is usually run as a batch job, though it can be run from a terminal directly or as a "streamed" job.
-
Reformatting Specifications Running REFORMAT These commands will run REFORMAT using the three files specified in the :FILE commands. Next, issue the following commands: :FILE OUTENTITY =outputfilename;ACC=APPEND :FILE BATCH=secondbatchfilename :RUN REFORMAT.PUB.SYS The outputfile now contains the reformatted data from the first and second batch files. Using a User-Defined Command You may want to combine the three :FILE commands required to run REFORMAT into one user-defined command (UDC).
-
Reformatting Specifications Running REFORMAT In many cases, a streamed job is part of a group of streamed jobs. When REFORMAT is part of a series of program executions, you should precede the RUN REFORMAT command by a MPE :CONTINUE command. Otherwise, any fatal error in REFORMAT (such as an inappropriate file name) prevents subsequent programs from executing. For example: !JOB !FILE ... !FILE ... !FILE ... !CONTINUE !RUN REFORMAT.PUB.SYS !SPLGO MYPROG !EOJ . . .
-
Reformatting Specifications Running REFORMAT 226 Chapter 5
-
USING VPLUS INTRINSICS Multipurpose 6 USING VPLUS INTRINSICS A set of callable intrinsics is provided by VPLUS. Table 6-1. lists the VPLUS intrinsics in alphabetic order and summarizes their functions. A full description of each intrinsic appears later in this section. They can be used by any application, either for data entry or for other terminal related applications.
-
USING VPLUS INTRINSICS Error Detection Error Detection If a system or program error causes a VPLUS intrinsic to fail, an error code is returned to the calling program. Once an error has been detected, subsequent intrinsic calls do not perform any functions until the program detects the error and performs its own error routine. In order for processing to continue after an error is detected, the calling program must reset the error argument.
-
USING VPLUS INTRINSICS Error Detection Table 6-1. Summary of VPLUS Intrinsics INTRINSIC FUNCTION VPOSTBATCH Updates end of file mark in batch file after last record referenced. VPRINTFORM Prints current form and data buffer on off-line list device. VPRINTSCREEN Prints entire contents of screen on off-line list device. VPUTBUFFER Copies data from application to data buffer. VPUTFIELD Copies data from application to field in data buffer.
-
USING VPLUS INTRINSICS HOW INTRINSICS ARE USED HOW INTRINSICS ARE USED The VPLUS intrinsics control the interface between forms stored in a forms file, a terminal screen, data entered on a form, and an application. Table 6-1. illustrates the relation between the VPLUS intrinsics, terminal, forms file, application, data file or optional batch file, and the buffer areas in memory used by the intrinsics. The intrinsics use a buffer area in memory for the form definition and another buffer area for the data.
-
USING VPLUS INTRINSICS HOW INTRINSICS ARE USED buffer with VPUTFIELD or VPUTtype. Conversely, the data buffer can be copied to an application with VGETBUFFER, or a single field can be copied with VGETFIELD or VGETtype. Figure 6-1.
-
USING VPLUS INTRINSICS HOW INTRINSICS ARE USED As is done in ENTRY, during data collection, data in the data buffer can be written to the batch file by VWRITEBATCH. The data in the batch file can be read from the batch file to the data buffer by VREADBATCH. Typically, data is read from the batch file for display at the terminal during browse and modify operations. Window Area If the field editing specifications detect an error in data entry or data movement, an error flag is set for the field.
-
USING VPLUS INTRINSICS CALLING VPLUS INTRINSICS CALLING VPLUS INTRINSICS The examples in Table 6-2. show the format for calls to the VPLUS intrinsics from each language, where: intrinsicname Identifies the intrinsic being called. parameter At least one parameter is required for each intrinsic; the particular parameters are listed in the formats for the individual intrinsic descriptions. Table 6-2.
-
USING VPLUS INTRINSICS CALLING VPLUS INTRINSICS Table 6-3. Data Types Used for Various Languages Data Type COBOL FORTRAN BASIC PASCAL SPL Character DISPLAY PIC X(n) Character String Packed Array of Char Byte Array Two-byte Integer COMP PIC S9 thru PIC S9(4) Integer*2 Integer Subrange -32768.. 32767 Integer Unsigned Two-byte Integer COMP PIC 9 thru PIC 9(4) Logical Integer (with value <32767) Subrange 0..
-
USING VPLUS INTRINSICS COMMUNICATION AREA COMMUNICATION AREA Every application that calls VPLUS intrinsics must allocate a data area in the application for communication with the intrinsics. This area (called the comarea) is the first, and often the only, parameter in every call to a VPLUS intrinsic. Table 6-4. briefly outlines the contents of this communication area; Table 6-5. outlines the items used for data capture devices.
-
USING VPLUS INTRINSICS COMMUNICATION AREA Table 6-4. Outline of Communication Area Contents Data Type Position Offset Name Function 34 33 showcontrol control flags for VSHOWFORM Integer (Two-byte) 35 34 Reserved for system use.
-
USING VPLUS INTRINSICS COMMUNICATION AREA Not supported on data capture devices. Table 6-5.
-
USING VPLUS INTRINSICS COMMUNICATION AREA language to the code for the programming language you are using. If you are coding in BASIC, you must set usrbuflen to the number of two-byte words needed for the comarea extension. This value is displayed on the forms file listing generated by FORMSPEC. Finally, in order to provide for possible future extensions to comarea, set comarealen to its current total length. Parameters cstatus Two-byte integer to which the intrinsic status is returned.
-
USING VPLUS INTRINSICS COMMUNICATION AREA function key pressed at a standard terminal, the last field touched for a touch terminal, or the last key pressed for data capture devices.
-
USING VPLUS INTRINSICS COMMUNICATION AREA Table 6-6. Codes for the Window Line Enhancement @ A B C D E F G Half-Bright X Underline X Inverse Video X Blinking Stop enhancement multiusage X X X X X X X X H I J K L M N O X X X X X X X X X X X X X X X X X X X X X X Two-byte integer that indicates whether the current form is in the same family as the previous form but is not the parent form.
-
USING VPLUS INTRINSICS COMMUNICATION AREA head form, the current form is retrieved. There is a maximum of eight forms; after eight, each additional form replaces the most recent form. repeatapp $HEAD Retrieve first form displayed when the forms file is executed (the "head" form). $END For ENTRY only, terminate execution of VGETNEXTFORM; return to calling program without resetting any comarea items.
-
USING VPLUS INTRINSICS COMMUNICATION AREA this section). If lookahead is zero and a family member of the form specified as the next form is already in the terminal's local form storage memory, the new form is not loaded. Instead, the family member is changed into the required form when it is displayed. The lookahead feature is ignored if the terminal does not have form storage capability. deleteflag Two-byte logical flag that indicates whether the current batch record has been or is to be deleted.
-
USING VPLUS INTRINSICS COMMUNICATION AREA enabled until bit 8 is reset to 0. 7-1 = 0 The undefined bits (7-1) must be initialized to zero. 0 = 0 Do not enable the touch feature (default). 1 Enable the touch feature. Bits 15, 14, and 13 are used to override VSHOWFORM optimization (where only information that has changed since the last call to VSHOWFORM is written to the terminal screen). Bits 12 and 11 are used with VREADFIELDS on data capture devices.
-
USING VPLUS INTRINSICS COMMUNICATION AREA and windows to support local form storage, but only the first terminal port can be used. The formstoresize allows the user to control the number of entries allowed in the form storage directory on the user stack and must be set prior to opening the terminal and the forms file. The space required is listed on the forms file listing generated by FORMSPEC.
-
USING VPLUS INTRINSICS COMMUNICATION AREA the programmer wishes to enable the AUTOREAD, the following statement should be issued in COBOL: ADD 2 TO TERM-OPTIONS. Conversely, if disabling the AUTOREAD feature, the programmer should subtract 2 from termoptions. For more information on the AUTOREAD feature, please consult Appendix G. environ First byte is the logical device number of the terminal. The remaining byte is reserved for system use.
-
USING VPLUS INTRINSICS COMMUNICATION AREA • 2 - multifunction reader • 3 - RS232 interface • 4 - typeV badge reader • 5 - magstripe reader • 6 - bar code reader • 7 - HP-IB interface rightmodule MPE determines which, if any, module is present.
-
USING VPLUS INTRINSICS COMMUNICATION AREA lightsOn Two two-byte integers to indicate whether or not lights are to be turned on during run time. The turning on of lights here does not affect the lights turned on during form design (in the Process Specification area of the form). • 0 - OFF • 1 - ON The default value is OFF, but this may be changed as follows: TWO-BYTE WORD 1, a "1" in: bit position 0 > turns light of key "@" ON 1 "A" ON 2 "B" ON ... ...
-
USING VPLUS INTRINSICS ERROR HANDLING ERROR HANDLING There are basically two types of errors that can occur as a result of calling VPLUS intrinsics. The first type consists of errors in the intrinsic call itself or in an attempt to access a file used by the called intrinsic. The second type are errors detected by editing data entered into FORMSPEC forms. These two error types are handled differently by VPLUS.
-
USING VPLUS INTRINSICS ERROR HANDLING particular field errors. Error messages may be general VPLUS messages (see Appendix B), or custom messages specified during forms design with FORMSPEC. In either case, the message is returned to the calling program by VERRMSG. VERRMSG determines the type of the error by examining cstatus and numerrs. If cstatus is not zero, its value indicates a particular intrinsic call error.
-
USING VPLUS INTRINSICS USING TERMINAL FEATURES USING TERMINAL FEATURES VPLUS provides a way to take advantage of special terminal features, using processing specifications (refer to Section 4), VPLUS intrinsics, and selections on the FORMSPEC menus (refer to Section 3). Two of the special terminal features that can be controlled with VPLUS intrinsics are touch and local form storage, as described below. Refer to Appendix G for a list of terminals that support these features.
-
USING VPLUS INTRINSICS USING TERMINAL FEATURES terminal memory into from one to four workspaces to store forms. Total available space is equal to 119 lines of forms, with the minimum size of a workspace being 26 lines. One full-screen window is used to display a form. A form is displayed by attaching a workspace to the window. Any enhancements and data entered onto the form are part of the form as long as it is in the terminal — a "fresh" form is not available in local storage.
-
USING VPLUS INTRINSICS USING TERMINAL FEATURES • Call VLOADFORMS. When VSHOWFORM is called to display a form, it searches the form storage directory to determine whether or not the form is already in the terminal. If the form is in local storage, VSHOWFORM displays it on the screen. If the form is not in local storage, VSHOWFORM preloads it into the terminal before displaying it when bit 9 of the comarea variable showcontrol is set to one.
-
USING VPLUS INTRINSICS USING TERMINAL FEATURES Appending Forms and Local Storage The implementation of appending forms differs between the HP 2626A and the HP 2624B/HP 2394A terminals. On the HP 2626A, the appending form is always written to the screen from the form definition area of memory rather than being displayed from local storage. If, however, the appending form has 24 or more lines (23 or more if a message window is defined), it is handled as an independent form rather than as an appending one.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS INTRINSIC DESCRIPTIONS The intrinsics on the following pages are described in alphabetic order for easy reference. However, this is not the order in which they are normally used. Table 6-7. is provided to group the intrinsics according to the functions they perform. Note that terminal access is performed by only seven intrinsics: VOPENTERM, VCLOSETERM, VPLACECURSOR, VSHOWFORM, VREADFIELDS, VLOADFORMS, and VUNLOADFORM.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Figure 6-2. Intrinsic Flow A Chapter 6 1) VOPENTERM, VOPENFORMF VOPENBATCH 2) VGETLANG Determine whether the forms file is a language-dependent forms file. 3) VSETLANG If international forms file, specify a native lanuage for language-dependent editing. Open terminal, forms file, optional batch file Load forms into terminal memory (for terminals with local form storage capability.) 4) VLOADFORMS 5) VGETNEXTFORM Retrieve form from forms file.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Figure 6-2 Intrinsic Flow Continued: 10) VSHOWFORM Display Form (can be preloaded first if terminal has local form storage capabiliity) 11) VPLACECURSOR Position cursor to the desired field. 12) VREADFIELDS User presses enter; data is read into data buffer.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Dependency Between Intrinsics Certain intrinsics must be called before other intrinsics can be executed. Figure 6-3. illustrates the standard dependencies among intrinsics. For example, the terminal file must be opened before any other intrinsics are called if prompts are to be sent to the terminal. Each of the three files, terminal, forms and batch must be opened before operations can be performed on these files and before the files can be closed. Figure 6-3.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VARMSCP Arms or disarms cursor sensing capability. Syntax VARMSCP {comarea,scpenable} Parameters comarea VARMSCP Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VARMSCP: cstatus Set to zero. comarealen Set to total number of two-byte words comarea. Must be at least 70 words in length. May set the following comarea item, cstatus.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VBLOCKREAD The VBLOCKREAD intrinsic reads a block of characters from a terminal in block mode. The syntax and parameter descriptions for this intrinsic are provided below. VBLOCKREAD {COMAREA,BUF,LEN,ACTLEN,TMODE,LOC,BC,TC} COMAREA The following COMAREA fields must be set before calling VBLOCKREAD, if not already set: LANGUAGE Set to code identifying the programming language of the calling program. COMAREALEN Set to total number of 2-byte words in COMAREA.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS of the MDT feature. The following examples illustrate a call to VBLOCKREAD using common programming languages: COBOL: CALL “VBLOCKREAD” USING COMAREA @ BUF LEN ACTLEN TMODE LOC BC TC.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VBLOCKWRITE The VBLOCKWRITE intrinsic writes a block of characters to a terminal in block mode. The syntax and parameter descriptions for this intrinsic are provided below. VBLOCKWRITE {COMAREA,BUF,LEN,TMODE,LOC,TC} COMAREA The following COMAREA fields must be set before calling VBLOCKWRITE, if not already set: LANGUAGE Set to code identifying the programming language of the calling program. COMAREALEN Set to total number of 2-byte words in COMAREA.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VREADFIELDS, lock the keyboard as soon as the terminal begins transmitting data when triggered by the Enter key or a function key. VOPENTERM must be called before using this procedure. This procedure is intended only for advanced programmers who are proficient with terminal control operations and VPLUS terminal settings.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VCHANGEFIELD Allows dynamic field attribute definition. Syntax VCHANGEFIELD {comarea,specbuffer,numentries} Parameters comarea Must be comarea specified when forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VCHANGEFIELD: cstatus Set to zero. language Set to code identifying the programming language of the calling program. comarealen Set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Table 6-8.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VCLOSEBATCH Closes an open batch file. Syntax VCLOSEBATCH" {comarea} Parameters comarea Must be name of comarea specified in VOPENBATCH call that opened this batch file. If not already set, the following comarea items must be set before calling VCLOSEBATCH: cstatus Set to zero. comarealen Set to total number of two -byte words in comarea. VCLOSEBATCH may set the following comarea items: cstatus Set to nonzero value if call unsuccessful.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VCLOSEFORMF Closes an open forms file. Syntax VCLOSEFORMF {comarea} Parameters comarea Must be comarea specified when forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VCLOSEFORMF: cstatus Set to zero. comarealen Set to total number of two-byte words in comarea. VCLOSEFORMF may set the following comarea items: cstatus Set to nonzero value if call unsuccessful.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VCLOSETERM Closes an open terminal file. Syntax VCLOSETERM {comarea} Parameters comarea Must be comarea named when file was opened by VOPENTERM. If not already set, the following comarea items must be set before calling VCLOSETERM: cstatus Set to zero. comareaten Set to total number of two-byte words in comarea. VCLOSETERM may set the following comarea items: ctstatus Set to nonzero value if call unsuccessful.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VERRMSG Returns a message corresponding to the error number of an edit error or an intrinsic call error. Syntax VERRMSG {comarea,buffer,buflen,actualen} Parameters comarea Must be comarea named when forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VERRMSG: language Set to code identifying the programming language of the calling program.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS The errfilenum contains the MPE file number of the VPLUS error message file. This file contains the error numbers and their associated messages for both intrinsic call and edit errors. It does not contain custom error messages, which are retrieved by VERRMSG through the form definition. VERRMSG opens this file if errfilenum equals zero when VERRMSG is called; it then sets errfilenum to the MPE file number of the file.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VFIELDEDITS Edits data entered in each field of form and, if indicated, modifies data in the data buffer. If necessary, sets error flags. Syntax VFIELDEDITS {comarea} Parameters comarea Must be comarea name specified when forms file was opened with VOPENFORMF. If not set already, the following comarea items must be set before calling VFIELDEDITS: cstatus Set to zero. comarealen Set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Table 6-9. Actions Used by Intrinsics Intrinsic Action VGETNEXTFORM Initializes all the error flags to zero. VFIELDEDITS VFINISHFORM VINITFORM VSETERROR Each may set field error flags on, increment numerrs, and set an internal error number used by VERRMSG. VSHOWFORM Enhances the fields whose error flags are set. VREADFIELDS Resets the flags to zero after the form is displayed.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VFINISHFORM Performs any processing specifications defined for the final phase of fields editing. Syntax VFINISHFORM {comarea} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VFINISHFORM: cstatus Set to zero. comarealen Set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETARBINFO A new VPLUS intrinsic has been added to retrieve the VPLUS ARB field mapping information. The intrinsic is named VGETARBINFO and is callable as follows: CALL “VGETARBINFO” USING VPLUS-COMAREA, ARB-INFO-BUF, INFO-BUF-LEN. Record VPPLUS-COMAREA << use existing definitions >> Record ARB-INFO-BUF: Record ARB-INFO-HEADER: 2 byte integer NUM-OF-ENTRIES; 2 byte integer ENTRY-LEN; 6 byte array FORM-NAME; 16 byte array FILLER; 2 byte integer NUM-ARB-FLDS.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS assigned by FORMSPEC. ARB-DATA-TYPE at output contains field type conversion notation from FORMSPEC, for example, CHAR, DINT, SPACK2, or token $NOTARBFLD, which indicates that the requested field does not exist within the ARB. ARB-DATA-LEN at output contains ARB field length in bytes (not updated if field does not exist in ARB). ARB-BUF-OFFSET at output contains zero relative byte offset of the ARB field (not updated if field does not exist in ARB).
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETBUFFER Copies entire contents of data buffer from memory to an application. Syntax VGETBUFFER {comarea,buffer,buflen} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VGETBUFFER: cstatus Set to zero. language Set to the code identifying the programming language of the calling program.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Special Considerations Designers using the ARB feature in VGETBUFFER should be aware that damaging run-time errors could occur if the application is inadvertently run on a system that has a VPLUS version earlier than B.05.00. To prevent this, the designer should do three things: 1. Document the product with a clear warning that VPLUS version B.05.00 or later MUST be used. 2. Use the VPLUS intrinsic HP32209 in the code.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETFIELD Copies contents of specified field from data buffer in memory to an application. Syntax VGETFIELD {comarea,fieldnum,fieldbuf,buflen,actualen,nextfldnum} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VGETFIELD: cstatus Set to zero. language Set to the code identifying the programming language of the calling program.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS If the number of bytes specified by buflen is less than the field size, the rightmost bytes are truncated. If the requested field has an error, its value is returned, but cstatus is set to an error number indicating the field error flag is set.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETFIELD(COMAREA,FIELD,PARTDES,LEN,ACTUAL'LEN,NEXT'FLD); Assume that the contents of field number "2" is to be copied, and that the length of this field is 12 bytes. The calls shown above copy the contents of this field into a variable in an application.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETFIELDINFO Returns information about specified fields to an application. Syntax VGETFIELDINFO {comarea,infobuf,infobuflen} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VGETFIELDINFO: cstatus Set to zero. comarealen Set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS field, and the name of the form containing the fields. Table 6-10.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Example COBOL DATA DIVISION. : : WORKING-STORAGE SECTION. 01 INFOBUF. 05 NUMBER-OF-ENTRIES PIC S9(4) COMP. 05 ENTRY-LENGTH PIC S9(4) COMP. 05 FORM-NAME PIC X(15). 05 FILLER PIC X. 05 ENTRY-TABLE OCCURS 10 TIMES. 10 FIELD-NAME PIC X(15). 10 FILLER PIC X. 10 SCREEN-ORD-NUM PIC S9(4) COMP. 10 FIELD-NUM PIC S9(4) COMP. 10 FIELD-LENGTH PIC S9(4) COMP. 10 FIELD-POSITION PIC S9(4) COMP. 10 FIELD-ENHANCE PIC X(4). 01 INFOBUFLEN PIC S9(4) COMP VALUE 80.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETFILEINFO Returns information about forms file to an application. Syntax VGETFILEINFO {comarea,infobuf,infobuflen} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VGETFILEINFO: cstatus Set to zero. comarealen Set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Table 6-11. File Information Buffer Data Type Position Contents Comments Integer (Two-byte) 1 numofentries Required 2 entrylength Required Integer Array (Four-byte) 3-4 File version number A date/time stamp, recorded at last forms file compile. Integer (Two-byte) 5 Number of forms in file 6 Maximum number of fields In any one form 7 Maximum data buffer size in two-byte words Of any one form, plus up to one additional two-byte word.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS 10 WINDOW-ENHANCE PIC X(4). 10 WINDOW-POSITION PIC S9(4) COMP. 01 INFOBUFLEN PIC S9(4) COMP VALUE 21. : : PROCEDURE DIVISION. : : MOVE SPACES TO INFOBUF. : : MOVE 1 TO NUMBER-OF-ENTRIES. MOVE 19 TO ENTRY-LENGTH. CALL "VGETFILEINFO" USING COMAREA, INFOBUF, INFOBUFLEN. The example shown above illustrates the data declaration of infobuf and infobuflen and the passing of parameters to VGETFILEINFO.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETFORMINFO Returns information about specified forms to an application. Syntax VGETFORMINFO {comarea,infobuf,infobuflen} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VGETFORMINFO: cstatus Set to zero. comarealen Set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Table 6-12. Form Information Buffer Data Type Position Contents Comments Integer (Two-byte) 1 numofentries Required 2 entrylength Required Character Array (16-byte) 3-10 Form name Permissible key; last byte of position 10 is unused (15 bytes maximum).
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Error Determination To enable applications to determine which fields are in error for a given form at run-time, VGETFORMINFO optionally returns a 32-byte bit map containing these error flags to show which fields failed the edit checks. Each field in a form is represented by a bit in the bit map according to its field creation number. The bit map is a 32-byte logical array to accommodate the maximum of 255 field numbers.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS 10 NEXT-FORM PIC X(15). 10 FILLER PIC X. 10 REPEAT-OPTION PIC X. 10 NFORM-OPTION PIC X. 01 INFOBUFLEN PIC S9(4) COMP VALUE 62. : PROCEDURE DIVISION. : MOVE SPACES TO INFOBUF. : MOVE 3 TO NUMBER-OF-ENTRIES. MOVE 20 TO ENTRY-LENGTH. MOVE "FORM1 " TO FORM-NAME. CALL "VGETFORMINFO" USING COMAREA, INFOBUF, INFOBUFLEN. The example shown above illustrates the data declaration of infobuf and infobuflen and the passing of parameters to VGETFORMINFO.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETKEYLABELS Retrieves global or current form function key labels. Syntax VGETKEYLABELS {comarea,formnorglob,numoflabels,labels} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VGETKEYLABELS: cstatus Set to zero. language Set to the code identifying the programming language of the calling program.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS CALL "VGETKEYLABELS" USING COMAREA,FORM-OR-GLOB,NUM-OF-LABELS,KEY-LABELS.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETLANG Returns the native language ID assigned to the forms file. For more information on Native Language Support, see Section 8. Syntax VGETLANG {comrea, langnum} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VGETLANG: cstatus Set to zero. comarealen Set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETNEXTFORM Reads the next form from an open forms file into the form definition area of memory. Syntax VGETNEXTFORM {comarea} Parameters comarea Must be comarea name specified when the forms file, from which the form is to be retrieved, was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VGETNEXTFORM: cstatus Set to zero. comarealen Set to total number of two-byte words in comarea. cmode Set to zero.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Discussion below for more information. repeatapp Set to value read from forms file for this (current) form. freezapp Set to value read from forms file for this (current) form. dbuflen Set to length (in bytes) of the current form just read from the forms file. Discussion VGETNEXTFORM checks the value of repeatapp passed in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETSAVEFIELD Copies contents of the specified save field from save field buffer in memory to an application. Syntax VGETSAVEFIELD {comarea,sfname,sfbuf,buflen,actualen} Parameters comarea must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VGETSAVEFIELD: cstatus set to zero.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Example COBOL CALL "VGETSAVEFIELD" USING COMAREA SFNAME SFBUF BUFLEN ACTLEN. SPL VGETSAVEFIELD(COMAREA,SFNAME,SFBUF,BUFLEN,ACTLEN); These calls will transfer the contents of the save field specified by SFNAME to SFBUF. If the call is successful, ACTLEN will contain the exact number of bytes transferred.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETSCPDATA Returns information about the cursor position by field number and row and column on a VPLUS screen. Syntax VGETSCPFIELD {comarea,fieldnum,screenrow,screencol} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VARMSCP: cstatus Set to zero. comarealen Set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS position information, then deletes the cursor position information upon procedure completion. Example COBOL CALL “VGETSCPDATA” USING COMAREA FIELDNUM SCREENROW SCREENCOL. SPL VGETSCPDATA (COMAREA,FIELDNUM, SCREENROW,SCREENCOL); These examples return the cursor position on the last read in the fieldnum, screenrow and screencol variables.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETSCPFIELD Returns information about the cursor position by field number on a VPLUS screen. Syntax VGETSCPFIELD {comarea,fieldnum} Parameters comarea fieldnum Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VARMSCP: cstatus Set to zero. comarealen Set to total number of two-byte words in comarea. Must be at least 70 words in length.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETtype Copies character coded data contents from data buffer into an application, converting numeric value to specified type.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS variable Variable within application, of type specified in VGETtype, into which converted value is placed. Discussion If there is no ARB, all data is read from the unprotected fields on the screen as character strings and concatenated to create a data buffer. The VGETBUFFER intrinsic copies the entire buffer to an application program or VGETFIELD can be used to obtain the contents of an individual field.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Table 6-13. Numeric Type Conversions Type Format LONG Floating -point format using eight-bytes; sign bit in bit 0; an exponent (biased by +256) in bits 1 through 9, and a positive fraction in the remaining 54 bits in HP 3000 format. (Not used by COBOL programs.) PACKED COBOL only; comp-3. See COBOL II/3000 Reference Manual. ZONED COBOL only. See COBOL II/3000 Reference Manual. YYMMDD Six-byte ASCII, in format YYMMDD; for example, 870623.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS status word. 6. VGETINT and VGETDINT only convert the integer portion of a given field. The fractional portion is truncated before conversion. Remember that in a field of type IMPn, the rightmost "n" characters are treated as a fraction. 7. Note that if VGETFIELD is used to pass a field containing a decimal point to a COBOL program, the decimal point is also passed and no arithmetic may be performed on the field. 8.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VGETYYYYMMDD Converts data in the data buffer to a eight-byte character value and copies it to an application. Syntax VGETYYYYMMDD {comarea,fieldnum,variable} Parameters comarea must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VGETYYYYMMDD: cstatus set to zero. comarealen set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VINITFORM Initializes fields in data buffer according to specifications defined in the initialize phase of field definition. Both VOPENFORMF and VGETNEXTFORM must have been executed successfully prior to calling VINITFORM. Syntax VINITFORM {comarea} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS FORTRAN CALL VINITFORM(COMAREA) SPL/PASCAL VINITFORM(COMAREA); The calls shown above set initial values in the data buffer area of memory according to initialize specifications defined for each field in the current form.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VLOADFORMS Loads specified forms into terminal local form storage memory. Syntax VLOADFORMS {comarea,numofforms,formsloaded,forms} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VLOADFORMS: cstatus Set to zero. language Set to the code identifying the programming language of the calling program.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Example COBOL 77 NUM-OF-FORMS 77 FORMS-LOADED 77 FORMS : MOVE 1 TO NUM-OF-FORMS MOVE "FORMA CALL "VLOADFORMS" USING PIC S9(4)COMP. PIC S9(4)COMP. PIC X(16). "TO FORMS. COMAREA, NUM-OF-FORMS, FORMS-LOADED, FORMS.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VMERGE VMERGE is a new VPlus utility that allows you to combine two or more separately-compiled VPlus forms files into a single forms file, which may then be used with an application program to manage the entry and/or retrieval of data. Combining multiple forms files with VMERGE provides the following advantages: • Some file size limitations can be overcome.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS to fit into a VFORM file. Now, VMERGE gives you an alternate method for generating VFAST files that contain additional forms. However, VFAST files still have limited capacity, and so there are still limits on the total number of forms you can place in a forms file, even using VMERGE. Initial analysis shows that the ratio of fast form file size to slow form file size is around 1/3 to 1/10.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS originated from the same forms file. VMERGE users should be aware that VMERGE makes the $HEAD form from VMASTER the $HEAD for VOUTPUT. If data entry operators are used to seeing the $HEAD form from the VAUX file, they may be surprised if this $HEAD form is no longer what is displayed when they bring up their application. Technical Reference VMERGE normally resides in PUB.SYS; if it is moved from PUB.SYS, it must be moved to a group with “DS” capability.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS them. Additionally, you will need to check that the global function key specifications are compatible in the three forms files. Note that in some cases incompatibilities may be so extensive that it will be impossible to merge the forms files. Next you determine what order to merge the forms files together. Suppose in this example that the marketing forms file is much more volatile than the other two.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS dependencies exist. The compilation for BIGFF will be lengthy, but it will only need to be done once. Fifth, you would make your changes to the forms in LITTLEFF and add additional forms that could not be put into BIGFF due to size limitations. After you had taken all these steps you could combine the two forms files with VMERGE: :FILE VMASTER=BIGFF :FILE VAUX=LITTLEFF :FILE VOUTPUT=SUPERFF :RUN VMERGE.PUB.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VOPENBATCH Opens existing batch file for processing; or, if the specified file is new, creates a batch file and then opens it for processing. Syntax VOPENBATCH {comarea,batchfile} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VOPENBATCH: cstatus Set to zero.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VOPENBATCH also resets the global environment (save fields and so forth) to the environment existing when collection stopped. (All this information is derived from the file labels preceding each file.) New File If the named file does not exist, VOPENBATCH creates a new file with the specified name and sets recnum and numrecs to zero.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS information is stored as follows: # of Bytes 2 — Product number 2 — (System use) 4 — Forms file version (date and time of compilation) 16 — Next form name 28 — Forms file name 120 — Reserved for system use 4 — Number of nondeleted records in batch file Total = 176 For example, assume that the save fields buffer requires 242 bytes.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS collection only, the batch file information is stored immediately following the data in each record. Assume a variable-length record with 35 bytes of data: 1 ( bytes) 35 data 37 56 brinfo odd byte is wasted even-byte boundary The total size of this record is 56 bytes. Depending on the size of the data, other records have varying lengths.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VOPENFORMF Opens forms file for access. Syntax VOPENFORMF {comarea,formfile} Parameters comarea The comarea name must be unique for each open forms file. If not already set, the following comarea items must be set before calling VOPENFORMF: cstatus Set to zero. language Set to the code identifying the programming language of the calling program. comarealen Set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS splitmsgpause Set to default or user specified value. formfile Character string of up to 36 characters (including a terminator) that identifies the forms file being opened. Specified name can be any fully qualified MPE file name. Discussion VOPENFORMF opens the specified forms file for processing by the calling application.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VOPENTERM Opens a VPLUS supported terminal. Syntax VOPENTERM {comarea,termfile} Parameters comarea The comarea name must be unique for each open forms file. The calling program should initialize the entire comarea to zero before calling VOPENTERM. For additional information about about using the pseudo intrinsic .LOC to put and address into a word of the COMAREA, refer to the COBOL II/XL Reference Manual.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS designator may be equated to an actual designator with a :FILE command. Discussion This intrinsic opens the terminal as a file. If you are running your program as a session with your terminal as the open terminal file, the terminal name should be left blank so that the session device is opened.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VPLACECURSOR Allows an application to position the cursor to any input field at run-time. Syntax VPLACECURSOR {comarea,fieldnum} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VPLACECURSOR: cstatus Set to zero. language Set to the code identifying the programming language of the calling program.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VPOSTBATCH Protects a user-specified portion of the batch file data from a system crash by posting an end-of-file mark after the last record referenced and updating the batch file labels. Syntax VPOSTBATCH {comarea} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VPOSTBATCH: cstatus Set to zero.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VPRINTFORM Prints the current form on an off-line list device. Syntax VPRINTFORM {comarea,printcnt1,pagecnt1} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VPRINTFORM: cstatus Set to zero. comarealen Set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS to the file number of the file. VPRINTFORM opens the list file, with the formal and actual file designator FORMLIST, assigns it to the device class LP, and specifies its length as 80 bytes. This is equivalent to using the file equation: :FILE FORMLIST;DEV=LP;REC=-80 A user may change any of these characteristics with an MPE :FILE command. Example COBOL CALL "VPRINTFORM" USING COMAREA, UNDERLINE, PAGE.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VPRINTSCREEN Prints the entire contents of a terminal screen to an off-line list device or laser printer during VPLUS execution. Syntax VPRINTSCREEN {comarea, readsize} Parameters comarea If not already set, the following comarea items must be set before calling VPRINTSCREEN: cstatus Set to zero comarealen Set to the total number of two-byte words in comarea. printfilenum Set to the file number of the list file to which the form is printed.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS 2. The INTRINSIC calling mechanism must be used when calling the VPLUS intrinsics from the main and all interacting parts of the application. For example, with COBOL the application must use: :CALL INTRINSIC Refer to Appendix E of this manual, and to the COBOL and Pascal reference manuals, for more information on calling mechanisms.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS called EPOCLIST is created (or appended to, if it already exists). EPOCLIST can be saved and renamed on completion of the screen capture, then input to TDP and 'finaled'. The user can add text to the file or include it in a separate TDP file. Refer to the TDP Reference Manual for more information on use and include files. The following files are sample files supplied on the FOS installation tape.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS HP2688) The screens will be printed out, one per page. Step 8 and 9 may be specified in a job stream. Merging Screens with a TDP File. You can include screens in an existing TDP document easily by using the file VEPOCUSE, a TDP use file that divides EPOCLIST into separate files containing one screen per file.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS but the code is set up to do so. • Screen images cannot be scaled; fonts come in one size only. • The maximum TDP record size is 168 characters. A single line in a screen may easily exceed this limit if it contains may escape sequences, in which case the line may be truncated. • TDP macros 5-9 are used to minimize truncation, but some screens will reach the limit anyway.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VPUTBUFFER Copies data from an application to the data buffer in memory. Syntax VPUTBUFFER {comarea,buffer,buflen} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VPUTBUFFER: cstatus Set to zero. language Set to the code identifying the programming language of the calling program.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS the 200 bytes of data moved to the data buffer with VPUTBUFFER. Fewer bytes than the data buffer can hold may be transferred; the remaining space in the data buffer is not changed. The data moved to the data buffer is exactly as it appears in the application buffer. (If you want the data converted to USASCII in the data buffer, you must use VPUTtype, where type is the data type of the field in an application.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VPUTFIELD Copies data from an application into a specified field in the data buffer in memory. Syntax VPUTFIELD {comarea,fieldnum,fieldbuf,buflen,actualen,nextfldnum} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VPUTFIELD: cstatus Set to zero. language Set to the code identifying the programming language of the calling program.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Note that VPUTFIELD does not convert the data. To convert data from internal numeric representation to character strings, you must use VPUTtype, where type specifies the data type of the field in an application. Example COBOL MOVE MOVE MOVE CALL 1 TO FIELDNUM. 10 TO FIELD-LEN. "GADGET "TO PART-DES. "VPUTFIELD" USING COMAREA, FIELDNUM, PART-DES, FIELD-LEN, DESC-LEN, NEXT-FIELD.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VPUTSAVEFIELD Copies data from an application to the specified save field in memory. Syntax VPUTSAVEFIELD {comarea,sfname,sfbuf,buflen,actualen} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VPUTSAVEFIELD: cstatus set to zero. language set to the code identifying the programming language of the calling program.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VPUTtype Copies a numeric value of specified type from an application to a field in the data buffer in memory, converting the value to character set coded external representation.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Discussion Depending on how it is specified, this intrinsic converts integer, double, real, long, packed, zoned or yymmdd values to the external representation and copies the converted value to a particular field in the data buffer, right justified. (Note that the exact format depends on the data type of the destination field.) The destination field is identified by the field number assigned by FORMSPEC.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS SPL/PASCAL INTEGER FIELD,ITEM; : FIELD:=4; ITEM:=25; VPUTINT(COMAREA,FIELD,ITEM); The calls shown above convert an integer value of 25 in the application to the external representation and copy it to field 4 in the data buffer in memory.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VPUTWINDOW Copies a message to the window area of memory. Syntax VPUTWINDOW {comarea,message,length} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VPUTWINDOW: language Set to the code identifying the programming language of the calling program. comarealen Set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS MSG="ENTER ORDERS ON THIS FORM" LEN=25 CALL VPUTWINDOW(COMAREA,MSG,LEN) SPL/PASCAL BYTE ARRAY MSG(0:24):="ENTER ORDERS ON THIS FORM"; INTEGER LEN; : LEN:=25; VPUTWINDOW(COMAREA,MSG,LEN); The calls shown above copy the message ENTER ORDERS ON THIS FORM to the window area of memory.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VPUTYYYYMMDD Converts a numeric value representing a date from an application and copies the converted value to a field in the data buffer in memory. Syntax VPUTYYYYMMDD {comarea,fieldnum,variable} Parameters comarea must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VPUTYYYYMMDD: cstatus set to zero.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VREADBATCH Reads contents of current batch record into data buffer in memory. Syntax VREADBATCH {comarea} Parameters comarea Must be comarea name used when the batch file was opened with VOPENBATCH. If not already set, the following comarea items must be set before calling VREADBATCH: cstatus Set to zero. comarealen Set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Example COBOL CALL "VREADBATCH" USING COMAREA. BASIC 175 CALL VREADBATCH(C(*)) FORTRAN CALL VREADBATCH(COMAREA) SPL/PASCAL VREADBATCH (COMAREA); The calls shown above read the batch record specified by recnurm update the comarea according to the batch record information stored with the data, and put the data in the data buffer in memory.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VREADFIELDS Accepts all user input from an open terminal, including data entered by pressing ENTER, or user requests made by pressing a function key. Allows look-ahead form loading. Syntax VREADFIELDS {comarea} Parameters comarea Must be comarea named specified when terminal file was opened with VOPENTERM. If not already set, the following comarea items must be set before calling VREADFIELDS: cstatus Set to zero.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS by the enter key or by a function key. Timeouts can be enabled in an application by setting bits in the termoptions word of the comarea and specifying a timeout interval in the usertime word of the comarea. For more information regarding user timeouts, consult the Terminal Communications Area section of Appendix G. For any terminal with touch capability, an application activates the touch feature by setting bit 0 of showcontrol to one.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS BASIC 130 CALL VREADFIELDS(C(*)) FORTRAN CALL VREADFIELDS(COMAREA) SPL/PASCAL VREADFIELDS(COMAREA); Each of the following calls accepts user input from the terminal, transfers any data to the data buffer, and sets lastkey.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VSETERROR Sets the error flag of a specified field and increments numerrs. If this is the first field (in screen order) with an error, it copies a message to the window area of memory for later display. Syntax VSETERROR {comarea,fieldnum,message,msglen} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VSETERROR: cstatus Set to zero.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Note that the field number identifies a field regardless of its position in the form. Thus, field "1" could be the third field in screen order counting from left to right, top to bottom. Using the field order number is preferable because if the fields in a form are rearranged, no modification to an application is necessary. Example COBOL DATA DIVISION. 77 FLDNUM PIC 9(4) COMP. 77 MESSAGE PIC X(80). 77 MLENGTH PIC S9(4) COMP. : PROCEDURE DIVISION.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS 230 L1=-1 CALL VSETERROR(C(*),F1,M$,L1) FORTRAN FF=3 ML=-1 CALL VSETERROR(COM1,FF,MSG,ML) SPL/PASCAL FIELD:=3; LEN:=-1; VSETERROR(COM1,FIELD,MESSAGE,LEN); Chapter 6 349
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VSETKEYLABEL Allows for temporarily setting, programmatically, a new label for a function key. Syntax VSETKEYLABEL {comarea,formorglob,keynum,label} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VSETKEYLABEL: cstatus Set to zero. language Set to the code identifying the programming language of the calling program.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS MOVE MOVE MOVE CALL 1 TO FORM-OR-GLOB. 1 TO KEY-NUM. "LABEL 1 " TO KEY-LABEL. "VSETKEYLABEL" USING COMAREA, FORM-OR-GLOB, KEY-NUM, KEY-LABEL.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VSETKEYLABELS Allows for temporarily setting, programmatically, labels for function keys. Syntax VSETKEYLABELS {comarea,formrglob,numoflabels,labels} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VSETKEYLABELS: cstatus Set to zero. language Set to the code identifying the programming language of the calling program.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS 77 KEY-LABELS PIC X(32). : MOVE 1 TO FORM-OR-GLOB. MOVE 2 TO NUM-OF-LABELS. MOVE "LABEL 1 LABEL 2 " TO KEY-LABELS. CALL "VSETKEYLABELS" USING COMAREA,FORM-OR-GLOB,NUM-OF-LABELS,KEY-LABELS.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VSETLANG The VSETLANG intrinsic specifies the native language to be used with an international forms file. For more information on Native Language Support, see Section 8. Syntax VSETLANG {comarea,langnum,errorcode} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VSHOWFORM Displays on the terminal screen the current form from local form storage or from the form definition buffer, any data in the data buffer, and any messages from the window buffer. Displays any labels from the key label buffer. Syntax VSHOWFORM {comarea} Parameters comarea Must be the comarea name specified when the terminal file was opened with VOPENTERM.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS setting the comarea item showcontrol as follows: bit 15 = 1 Force form to be written to the terminal screen. 14 = 1 Force data and field enhancements to be written to the terminal screen. 13 = 1 Force window line to be written to the terminal screen. Depending on the bits set, VSHOWFORM writes a form or data or the window to the terminal whether or not it has changed. Anything that has changed is always written to the terminal regardless of showcontrol.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Controlling the Keyboard As soon as the form is displayed, VSHOWFORM normally enables the keyboard so the user can enter data. The next call is usually to VREADFIELDS, which locks the keyboard after the entered data is read. In case of consecutive calls to VSHOWFORM, the following showcontrol bit can be set: bit 10 = 0 1 Enable the keyboard. Do not enable the keyboard.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS Example COBOL CALL "VSHOWFORM" USING COMAREA. BASIC 120 CALL VSHOWFORM(C(*)) FORTRAN CALL VSHOWFORM(COMAREA) SPL/PASCAL VSHOWFORM (COMAREA); The calls shown above display a form with optional data and enhancements on the terminal screen opened with the comarea, COM 1.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VTURNOFF The VTURNOFF intrinsic turns off VPLUS block mode and enables character mode access without disturbing the terminal screen. The syntax and parameter descriptions for this intrinsic are provided below. Syntax VTURNOFF {COMAREA} Parameters COMAREA Must be COMAREA name specified when the forms file was opened with VOPENTERM. If not already set, the following COMAREA items must be set before calling VTURNOFF: CSTATUS Set to zero.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS PASCAL: VTURNOFF(COMAREA); 360 Chapter 6
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VTURNON The VTURNON intrinsic turns on VPLUS block mode without disturbing the terminal screen. The syntax and parameter descriptions for this intrinsic are provided below. Syntax VTURNON {COMAREA,TERMFILE} Parameters COMAREA The COMAREA name must be unique for each open forms file. The COMAREA must be the same COMAREA used in VOPENTERM. The following COMAREA items must be set before the call, if not already set: CSTATUS Set to zero.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS CALL “VTURNON” USING COMAREA, T1.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VUNLOADFORM Unloads the specified form from local form storage memory. Syntax VUNLOADFORM {comarea,whichform} Parameters comarea Must be comarea name specified when the forms file was opened with VOPENFORMF. If not already set, the following comarea items must be set before calling VUNLOADFORM: cstatus Set to zero. language Set to the code identifying the programming language of the calling program.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS SPL/PASCAL BYTE ARRAY WHICH'FORM(0:15); : WHICH'FORM:="FORMA "; VUNLOADFORM(COMAREA,WHICH'FORM); 364 Chapter 6
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS VWRITEBATCH Writes a record to the batch file from the data buffer in memory, or deletes a record from the batch file Syntax VWRITEBATCH {comarea} Parameters comarea Must be comarea name specified when the batch file was opened with VOPENBATCH. If not already set, the following comarea items must be set before calling VWRITEBATCH: cstatus Set to zero. comarealen Set to total number of two-byte words in comarea.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS to the batch record specified by recnum. Modify Mode When data is modified, an existing batch file record is rewritten. The calling program must set recnum to the record number of this record. To mark a batch record as deleted, the deleteflag must be set to TRUE (all ones) by an application. Then a call to VWRITEBATCH sets a corresponding flag in the batch record to mark the record as deleted.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS In addition, assume the batch file opened by VOPENBATCH has fixed-length records, 80 bytes long. The call to VWRITEBATCH writes the following record as the sixth record in the batch file: 37 1 (bytes) A10035-9BICYCLE∆PUMP0010.95∆∆5054.
-
USING VPLUS INTRINSICS INTRINSIC DESCRIPTIONS 368 Chapter 6
-
USING FORMSPEC IN BATCH MODE USING FORMSPEC IN BATCH MODE 7 USING FORMSPEC IN BATCH MODE USING FORMSPEC IN BATCH MODE FORMSPEC in batch mode allows you to manage a forms file without tying up your terminal. With this feature, forms may be deleted from or copied to a forms file, compiled, and listed on a printer by accepting commands from a job stream or from a disc file or I/O device.
-
USING FORMSPEC IN BATCH MODE USING FORMSPEC IN BATCH MODE forms can be copied to or deleted from a forms file, field attributes may be updated, and function key labels may be created and updated. Individual screens, save fields, and some global information; however, cannot be defined in batch mode. Also, save fields cannot be copied from one forms file to another. Listing Forms Files in Batch Mode By using the batch mode LIST command, forms can be listed on the list device from a streamed job.
-
USING FORMSPEC IN BATCH MODE INVOKING FORMSPEC IN BATCH MODE INVOKING FORMSPEC IN BATCH MODE FORMSPEC in batch mode can be invoked from within a job stream or from within a session. When invoked, FORMSPEC can accept batch mode commands from a command file or from $STDIN. To invoke FORMSPEC to accept batch mode commands from a command file, use the MPE :RUN command with the INFO=filename parameter, where filename is the name of the command file. For example: :RUN FORMSPEC.PUB.SYS;INFO="COMMANDS.PUB.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS BATCH MODE COMMANDS The following pages show the syntax and description of the batch mode commands that FORMSPEC accepts in a command file or job stream. Table 7-1. gives a summary of the batch mode commands, a brief description of their functions, and the interactive counterpart for each command. Note that each command must be entered on a separate line and a command may not carry over to the next line. Leading blanks may be used for indentation.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS Table 7-1. FORMSPEC in Batch Mode Commands Command Function Interactive Counterpart SELECTLANG Updates native language specifications. FORMSPEC Terminal/Language Menu. SELECTTERM Updates terminal and device specifications. FORMSPEC Terminal/Language Menu. ARBTOSCREEN Set data type conversion defaults from ARB to screen. Select defaults on FORMSPEC Data Type Conversion Menu. SCREENTOARB Sets data type conversion rules from screen to ARB.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS COMPILE Compiles the current forms file. Syntax COMPILE [INTO fastfile] Parameters fastfile is the name of the fast forms file to which all code records are copied. Since a fast forms file contains only records needed by VPLUS/V intrinsics at run-time, it may be advantageous to compile the forms file into a fast forms file. If fastfile already exists and it is a fast forms file, it is replaced with this version.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS COPY Copies a form within the current forms file, or copies a form from another forms file to the current forms file. Syntax [COPY form {TO newform IN file [TO newform]}] Parameters form is the name of the form to be copied. newform is the name of the new form in the current forms file to which form will be copied. The newform cannot already exist in the forms file. If newform already exists, an error will occur and no copying will be done.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS DELETE Removes a form from the current forms file. Syntax DELETE form Parameters is the name of the form to be removed from the current forms file. If form does not exist, FORMSPEC will issue a warning and proceed to the next command. form Example DELETE ORDER2 removes the form ORDER2 from the current forms file.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS EXIT Terminates FORMSPEC in batch mode. Syntax EXIT Discussion The EXIT command is optional. FORMSPEC will also terminate after the last command in the command file is executed.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS FIELD Updates field attributes. Syntax {,newfieldname} {,enhancement } FIELDform {fieldtag } {,fieldtype } {oldfieldname} {,datatype } {,initialvalue} Parameters form is the name of an existing form within the current forms file. fieldtag tag assigned to the field in form screen design. oldfieldname name currently assigned to the field in the field menu. newfieldname replacement field name. enhancement replacement display enhancement code.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS FILE Specifies the current forms file to be used. Syntax FILE file Parameters is the name of the forms file to be used by subsequent batch mode commands. The file is referred to as the current forms file. file Discussion The FILE command must precede all other commands in a command file or job stream. This command opens the specified forms file to be operated on by the other batch mode commands.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS FKLABELS Updates function key labels. Syntax FKLABELS form [\keylabel ... \keylabel] Parameters form is the name of an existing form within the current forms file. keylabel literal which is to appear in the function key label. If $EMPTY is entered as the first six characters of keylabel, the existing key label is cleared. Discussion The FKLABELS command creates (if none exist) or updates function key labels for the specified form.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS FORMS Prints a summary listing for the forms in the current forms file. Syntax [FORMS [form] [@ ]] Parameters form The name of an existing form within the current forms file for which summary information is to be printed. If omitted, a summary of the current forms file is printed. @ The commercial at sign (@) specifies that summary information for all forms, as well as the current forms file, is printed.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS Example FORMS prints a summary of the current forms file, SYSADMIN in this example: Forms file: SYSADMIN.ACCTG.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS Example FORMS @ Prints a summary of the current forms file, (SYSADMIN) as well as the summary information for each form in the forms file, two in this example: Forms File: SYSADMIN.ACCTG.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS LIST Lists a specified form or all forms on the list device. Syntax LIST [form] Parameters is the name of the form in the current forms file to be listed. When form is not specified, all forms in the current forms file are listed. form Discussion The LIST command can be used to provide documentation for a forms file. The forms are usually listed on the line printer. The LIST command can also be used to list forms to a disc file to be examined.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS RELATE Creates a family relationship between two existing forms. Syntax RELATE childform TO parentform Parameters childform is the name of the form which is to become the child form. It must already exist, and not be related to any other form. parentform is the name of the form which is to become the parent form. It must already exist, and have the identical form design as the childform specified with the childform parameter.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS RENUMBER Renumber fields to screen order. Syntax RENUMBER form Parameters form is the name of the form containing the fields to be renumbered. Discussion The fields in the form specified by form are renumbered in accordance with screen order, left to right, top to bottom. If your application depends on field numbers, be sure to update your application to reflect the changed field numbers.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS SELECTLANG Updates native language specification. Syntax SELECTLANG [formsfilelangID] [,FORMSPEClangID] Parameters formsfilelangID Set forms file native language specification. FORMSPEClangID Set FORMSPEC native language specification. Discussion Only the first three characters of each parameter are used. Refer to "Setting Language ID Number" in Section 8 for more information. At least one parameter must be specified.
-
USING FORMSPEC IN BATCH MODE BATCH MODE COMMANDS SELECTTERM Updates forms file terminal or device specifications. Syntax SELECTTERM [262xand239x] [,color] [,264x] [,307x] Parameters 262xand239x Configure forms file for the HP 262X and HP'239X terminal families; also includes the HP 150. color Configure forms file for color terminals. 264x Configure forms file for the HP 264X terminal family. Specifying yes (the value Y or y) enables function key labeling.
-
USING FORMSPEC IN BATCH MODE ARB BATCH MODE COMMANDS ARB BATCH MODE COMMANDS The following batch mode commands support the ARB feature. They are based on the ARB Menu options provided in interactive FORMSPEC. The commands are summarized below, and each one is described in detail in the rest of this section.
-
USING FORMSPEC IN BATCH MODE ARB BATCH MODE COMMANDS ADDARBFIELD Add a field to the ARB. Syntax ADDARBFIELD arbname fieldname destination Parameters arbname Name of the ARB to which the field will be added. fieldname The name of the new field. destination Position at which the field is to be inserted. May be left blank. Discussion If the arbname doesn't exist, an ARB with this name will be created for the associated form. The ARB cannot contain the fieldname already.
-
USING FORMSPEC IN BATCH MODE ARB BATCH MODE COMMANDS ARBTOSCREEN Create/update the datatype conversion rules for converting ARB field contents to screen field contents. Syntax ARBTOSCREEN [chartype, inttype, realtype, packtype, zonetype] Parameters chartype The conversion type for ARB fields with type CHAR. inttype The conversion type for ARB fields with type INT or DINT. realtype The conversion type for ARB fields with type REAL or LONG.
-
USING FORMSPEC IN BATCH MODE ARB BATCH MODE COMMANDS DELARB Deletes the entire specified ARB. Syntax DELARB arbname Parameters arbname Name of the existing ARB. Discussion All the fields are deleted. You can generate another ARB for the specified form if required. If extensive changes are made to a form, it is easier to delete the existing ARB and create a new one than to revise the old ARB.
-
USING FORMSPEC IN BATCH MODE ARB BATCH MODE COMMANDS DELARBFIELD Deletes a specified field from the ARB. Syntax DELARBFIELD arbname fieldname Parameters arbname Name of the existing ARB. fieldname Name of the specified field on the ARB. Discussion The arbname must exist in the forms file and the fieldname must exist on the ARB.
-
USING FORMSPEC IN BATCH MODE ARB BATCH MODE COMMANDS GENARB Generates an ARB from the form specified by the formname. Syntax GENARB arbname Parameters arbname Same as the name of the associated form Discussion The ARB will contain a field for every field on the form. The data type and length of each ARB field are determined from the screen attributes and the Data Conversion table (set up using the Data Conversion Menu).
-
USING FORMSPEC IN BATCH MODE ARB BATCH MODE COMMANDS MODARBFIELD Modify the attributes of a field on an ARB. Syntax MODARBFIELD arbname fieldname {[length, type]} Parameters arbname Name of the ARB that contains the field to be modified fieldname The name of the field to be modified. [length, type] The new ARB field length and/or data type. Discussion The arbname must exist in the forms file and the fieldname must exist on the ARB.
-
USING FORMSPEC IN BATCH MODE ARB BATCH MODE COMMANDS MOVEARBFIELD Move a field or group of fields to a specified position on an ARB. Syntax MOVEARBFIELD arbname range [destination] Parameters arbname The name of the ARB. range The field or fields to be moved, expressed as fieldname or fieldname/fieldname. [destination] The position in the ARB to which the field(s) will be moved. Can be left blank. Discussion The arbname must exist.
-
USING FORMSPEC IN BATCH MODE ARB BATCH MODE COMMANDS RENAMEARBFIELD Change the name of oldfieldname to newfieldname in the ARB arbname. Syntax RENAMEARBFIELD arbname oldfieldname newfieldname Parameters arbname Name of the ARB that contains the field. oldfieldname The current name of the field. newfieldname The new game you want to give the field. Discussion This command does not change the ARB data type or length. The arbname must exist in the forms file, and the oldfieldname must exist on the ARB.
-
USING FORMSPEC IN BATCH MODE ARB BATCH MODE COMMANDS SCREENTOARB Create/update the datatype conversion rules for generating an ARB from a form. Syntax SCREENTOARB [chartype, datetype, digtype, numtype, imptype] Parameters chartype The conversion type for screen fields with type CHAR. datetype The conversion type for screen fields with a date type. digtype The conversion type for screen fields with type DIG. numtype The conversion type for screen fields with type NUM, NUM0, NUM1… NUM9.
-
USING FORMSPEC IN BATCH MODE SAMPLES OF FORMSPEC IN BATCH MODE SAMPLES OF FORMSPEC IN BATCH MODE The following are samples of how FORMSPEC in batch mode is used, first with a command file and then with the commands directly in the job stream. Sample Command File FORMSPEC in batch mode can be executed with the following commands: :FILE FORMOUT;DEV=LP :RUN FORMSPEC.PUB.SYS;INFO="FORMCMDS.PUB.MFG" The MPE :FILE command directs batch mode output (commands and error messages) to the list device.
-
USING FORMSPEC IN BATCH MODE SAMPLES OF FORMSPEC IN BATCH MODE Example << << << << << << << << << This command file updates the forms files, FORMSF1 and FORMSD2. FORMSF1 is opened first. Two forms are copied from the forms file MASTERFS.PUB. The FORMSF1 is then compiled into the fast forms file FASTFRM1. A listing is made of all the forms in FORMSF1. FORMSF1 is then closed and FORMSF2 opened as the current forms file. Two forms are copied from the forms file MASTERFS.
-
NATIVE LANGUAGE SUPPORT 8 NATIVE LANGUAGE SUPPORT VPLUS Native Language Support (NLS) enables an applications designer to create interactive user applications which reflect both the user's native language and the local custom for numeric and date information in the supported languages. (See Native Language Support Reference Manual for an explanation of supported languages.) NLS provides these specific features in VPLUS: • Native decimal and thousands indicators. • Native language month names for dates.
-
NATIVE LANGUAGE SUPPORT LANGUAGE ATTRIBUTE LANGUAGE ATTRIBUTE VPLUS contains an NLS native language attribute option which allows the applications programmer to design a forms file which reflects the native language characteristics of the application. Each forms file has a global native language ID number. The application may be unlocalized, language-dependent, or international.
-
NATIVE LANGUAGE SUPPORT NLS CAPABILITIES NLS CAPABILITIES The components of a form which can be language-dependent are the initial values of fields and the field edit rules. The text is fixed in a single native language by the forms designer. The native language ID number determines the context for data editing, conversion, and formatting. There are two native language IDs assigned for each forms file. The FORMSPEC language controls the context when the forms file is designed.
-
NATIVE LANGUAGE SUPPORT FIELD EDITS FIELD EDITS NATIVE-3000 must be used to specify date and numeric fields within FORMSPEC. When the forms file is executed, VPLUS will convert the value to be consistent with the native language selected. Single value comparisons (GT,GE,LT,LE,EQ,NE), as well as table and range checks (IN, NIN), specified within FORMSPEC may contain any character in the 8 bit extended character set consistent with the selected native language ID number.
-
NATIVE LANGUAGE SUPPORT ENTRY AND LANGUAGE lD NUMBER ENTRY AND LANGUAGE lD NUMBER The native language ID assigned for the forms file language determines the native language used by ENTRY unless the file is international (-1). ENTRY uses the intrinsic VGETLANG to identify the native language ID assigned by the forms designer for the forms file language. If the forms file is international, ENTRY calls the NLS intrinsic NLGETLANG (mode 1).
-
NATIVE LANGUAGE SUPPORT ENTRY AND LANGUAGE lD NUMBER 406 Chapter 8
-
SAMPLE PROGRAMS A SAMPLE PROGRAMS The VPLUS intrinsics can be called from the programming languages listed in Table A-1. The reference manuals to consult for each language are also listed. Table A-1.
-
SAMPLE PROGRAMS SPL SPL $PAGE "HP32209B.04.17 VPLUS/V S40S209B, ENTRY" $COPYRIGHT " $ " $ " (c) COPYRIGHT HEWLETT-PACKARD. 1986 " , " , " , " , " , " , " , " , " , >> $ "This program may be used with one computer system at a time $ "and shall not otherwise be recorded, transmitted or stored $ "in a retrieval system. Copying or other reproduction of this $ "program except for archival purposes is prohibited without $ "the prior written consent of the Hewlett-Packard Company.
-
SAMPLE PROGRAMS SPL $PAGE " "ENTRY DECLARATIONS" <<****************************************************************>> << >> << ENTRY Global Declarations >> << >> <<****************************************************************>> BEGIN DEFINE VERSION = " B.04.17" # ,ID’MSG=("HP32209",VERSION," ENTRY (C) HEWLETT-PACKARD CO.
-
SAMPLE PROGRAMS SPL ,HEADKEY = 1 ,DELETEKEY = 2 ,PRINTKEY = 3 ,REFRESHKEY = 4 ,PREVKEY = 5 ,NEXTKEY = 6 ,BROWSEKEY = 7 ,EXITKEY = 8 ; EQUATE << ENTRY ERROR EQUATES >> PREV’NOT’ALLOWED = 1 ,NO’PREV’RECS = 2 ,NOT’REPEATING = 3 ,DELETE’NOT’DEFINED = 4 ,NO’BATCH’RECS = 5 ,NO’BATCH = 6 ,NO’NEXT’RECS = 7 ; EQUATE << NATIVE LANGUAGE SUPPORT EQUATES >> INTERNATIONAL = -1 ; INTEGER ARRAY COMAREA (O:COMAREALEN-1) := COMAREALEN (0) ; BYTE ARRAY COMAREA’B (*) = COMAREA ; DOUBLE ARRAY COMAREA’D (*) = COMAREA ; LOGICAL E
-
SAMPLE PROGRAMS SPL $PAGE " VPLUS/V INTRINSIC DECLARATIONS" <<****************************************************************>> << >> << VPLUS/V INTRINSICS >> << >> <<****************************************************************>> INTRINSIC VCLOSEBATCH ,VCLOSEFORMF ,VCLOSETERM ,VERRMSG ,VFIELDEDITS ,VFINISHFORM ,VGETNEXTFORM ,VINITFORM ,VOPENBATCH ,VOPENFORMF ,VOPENTERM ,VPOSTBATCH ,VPRINTFORM ,VPUTWINDOW ,VREADBATCH ,VREADFIELDS ,VSHOWFORM ,VWRITEBATCH ,VGETKEYLABELS ,VSETKEYLABELS ,VSETKEYLABEL ,VSETL
-
SAMPLE PROGRAMS SPL << FUNCTION KEY 8 >> ," EXIT ); GLOB’FORM := 0; << GLOBAL LABELS >> NUMBER’OF’LABELS := 8; $$VSETKEYLABELS(COMAREA,GLOB’FORM,NUMBER’OF’LABELS, LABELS); END; <<****************************************************************>> << >> << DO’BROWSE’LABELS >> << >> <<****************************************************************>> PROCEDURE DO’BROWSE’LABELS; BEGIN BYTE ARRAY LABELS(0:127); INTEGER NUMBER’OF’LABELS,GLOB’FORM; MOVE LABELS := ( << FUNCTION << FUNCTION << FUNCTION << FUNCTION
-
SAMPLE PROGRAMS SPL $PAGE " FORMAT’STATUS’LINE" <<****************************************************************>> << >> << FORMAT’STATUS’LINE >> << >> <<****************************************************************>> PROCEDURE FORMAT’STATUS’LINE; BEGIN INTEGER CNT; INTRINSIC ASCII, DASCII; if com’term’type = 15 or << HP3075 >> com’term’type = 16 then << hp3076 >> move message’buf := (" ENTRY ", version, " "), 2 else MOVE MESSAGE’BUF := (" ENTRY ", VERSION, ESC, "&a31C"), 2; MSGLEN := TOS - @MESSAGE’
-
SAMPLE PROGRAMS SPL $PAGE " ENTRY’ERROR" <<****************************************************************>> << >> << ENTRY’ERROR >> << >> <<****************************************************************>> PROCEDURE ENTRY’ERROR (ENTRY’ERROR’NUM); VALUE ENTRY’ERROR’NUM; INTEGER ENTRY’ERROR’NUM; BEGIN IF ERRORS THEN RETURN; ERRORS := TRUE; CASE ENTRY’ERROR’NUM OF BEGIN << 0 IS NOT DEFINED >> ; << PREV’NOT’DEFINED: >> MOVE MESSAGE’BUF := " The PREV key is only defined for browse mode.
-
SAMPLE PROGRAMS SPL $PAGE" ERROR" <<****************************************************************>> << >> << ERROR >> << >> <<****************************************************************>> PROCEDURE ERROR; BEGIN IF ERRORS THEN RETURN; << WILL ONLY HANDLE FIRST ERROR! >> ERRORS := TRUE; MESSAGE’BUF := " "; VERRMSG (COMAREA, MESSAGE’BUF(1), MESSAGE’BUF’LEN, MSGLEN); MSGLEN := MSGLEN + 1; COM’STATUS := 0; VPUTWINDOW (COMAREA MESSAGE’BUF, MSGLEN); END; << ERROR >> Appendix A 415
-
SAMPLE PROGRAMS SPL $PAGE " ENTRY INITIALIZATION PROCEDURE" <<****************************************************************>> << >> << INIT >> << >> <<****************************************************************>> PROCEDURE INIT; BEGIN EQUATE VERSIONS’DIFF = 70 ,DIF’FF = 73 ,FILENAMELEN = 36 ,LANGID’LEN = 17 ; EQUATE BLANK’LINE = 0 ,GET’FF’NAME = 1 ,GET’BF’NAME = 2 ,DIF’FF’WARN = 3 ,VERS’DIF’WARN = 4 ,Y’TO’CONT = 5 ,PRODUCT’ID = 6 ,GET’LANGID = 7 ,NOT’CONFIG = 8 ,NOT’INSTALL = 9 ; INTEGER INDEX ,READ
-
SAMPLE PROGRAMS SPL INTRINSIC NLGETLANG ,NLINFO ; SUBROUTINE HANDLE’PROMPT’ERR (QUIT’NUM); VALUE QUIT’NUM; INTEGER QUIT’NUM; BEGIN MOVE MESSAGE’BUF := "Terminal access failed unexpectedly.
-
SAMPLE PROGRAMS SPL << 7, GET’LANGID >> MOVE MESSAGE’BUF :=(" ENTER LANGUAGE ID NUMBER AND PRESS", "RETURN: "),2; << 8, NOT’CONFIG >> MOVE MESSAGE’BUF := " Specified language is not configured ",2; << 9, NOT’INSTALL >> MOVE MESSAGE’BUF := " Native language Software not installed",2 ; END; << CASE >> MSGLEN := TOS - @MESSAGE’BUF; PRINT (MESSAGE’WBUF, -MSGLEN, CCTL); IF <> THEN HANDLE’PROMPT’ERR (2); END; << PRINT’TO’TERM >> INTEGER SUBROUTINE READ’FROM’TERM (READBUF, READLEN); VALUE READLEN; BYTE ARRAY RE
-
SAMPLE PROGRAMS SPL $PAGE << INITIALIZE COMAREA; IS ALL 0’S TO START >> COM’LANGUAGE := SPL’LANG; COM’COMAREALEN := COMAREALEN; << SET COM’LABEL’OPTION TO 1 TO ENABLE FUNCTION KEY LABEL << SUPPORT FOR TERMINALS SUPPORTING FUNCTION KEY LABELS COM’LABEL’OPTION := 1; >> >> << Set form storage buffer size (2626 terminal only) to 4 >> COM’FORM’STOR’SIZE := 4; BATCH := TRUE; << INIT >> PRINT’TO’TERM (PRODUCT’ID, %60); << ENTRY IDENTIFICATION >> WHILE TRUE DO BEGIN DO << UNTIL COM’STATUS = 0 >> BEGIN COM’STAT
-
SAMPLE PROGRAMS SPL IF COM’STATUS = 0 THEN BEGIN VGETLANG( COMAREA, LANGID ); IF COM’STATUS <> 0 THEN WRITE’MSG ELSE IF LANGID = INTERNATIONAL THEN BEGIN << IF INTERNATIONAL FORMS FILE PROMPT FOR LANGID >> CONTINUE := TRUE; LANGID := NLGETLANG( 1, NLERROR ); IF NLERROR = 0 THEN BEGIN VSETLANG( COMAREA LANGID, VERROR ); COM’STATUS := 0; END; WHILE CONTINUE DO BEGIN PRINT’TO’TERM( BLANK’LINE, %40 ); PRINT’TO’TERM( GET’LANGID, %320 ); READ’LEN := READ’FROM’TERM( LANGID’STR, LANGID’LEN ); IF READ’LEN = 0 THEN C
-
SAMPLE PROGRAMS SPL VCLOSEBATCH (COMAREA); VCLOSEFORMF (COMAREA); END; END; << WHILE TRUE >> END; << INIT >> Appendix A 421
-
SAMPLE PROGRAMS SPL $PAGE " EXIT" <<****************************************************************>> << >> << EXIT >> << >> <<****************************************************************>> PROCEDURE EXIT; BEGIN BYTE ARRAY LOCAL’MESSAGE’BUF (0:80); INTEGER LOCAL’MSGLEN; INTRINSIC PRINT; SUBROUTINE PRINT’MSG; BEGIN VERRMSG (COMAREA, LOCAL’MESSAGE’BUF, MESSAGE’BUF’LEN, LOCAL’MSGLEN); PRINT (LOCAL’MESSAGE’BUF, -LOCAL’MSGLEN, 0); COM’STATUS := 0; END; << FIRST, CLOSE TERMINAL >> COM’STATUS := 0; VCLOSETERM
-
SAMPLE PROGRAMS SPL $PAGE " BROWSE" <<****************************************************************>> << >> << BROWSE >> << >> <<****************************************************************>> PROCEDURE BROWSE; BEGIN EQUATE FORWARDS = 1 ,BACKWARDS = -1 ; INTEGER PAGE’EJECT := %61 ,UNDERLINE := 1 ,DIRECTION ; DOUBLE LOCAL’COM’REC ; DO’BROWSE’LABELS; LOCAL’COM’REC := COM’RECNUM; COM’RECNUM := COM’RECNUM - 1D; DIRECTION := BACKWARDS; WHILE TRUE DO BEGIN << UNTIL EXIT OR COLLECTKEY >> IF COM’NUMRECS = 0
-
SAMPLE PROGRAMS SPL IF COM’CFNAME <> COM’NFNAME, (15) THEN COM’REPEATOPT := NORM; << CLEAR SINCE NOT REPT >> IF COM’LASTKEY = REFRESHKEY THEN MOVE COM’NFNAME := "$REFRESH "; VGETNEXTFORM (COMAREA); CHECK’ERROR; LOCAL’COM’REC := COM’RECNUM; END; IF NOT ERRORS THEN FORMAT’STATUS’LINE; DO << WHILE ERRORS >> BEGIN ERRORS := FALSE; VSHOWFORM (COMAREA); CHECK’ERROR COM’SHOWCONTROL := 0; << RESET JUST IN CASE >> VREADFIELDS (COMAREA); CHECK’ERROR; if com’lastkey <> 0 then if com’term’type = 15 or << HP3075 >>
-
SAMPLE PROGRAMS SPL IF NOT ERRORS THEN BEGIN VWRITEBATCH (COMAREA); CHECK’ERROR; IF NOT ERRORS THEN COM’RECNUM := COM’RECNUM+1D; END; END; END; << HEADKEY: >> BEGIN DIRECTION := FORWARDS; COM’RECNUM := 0D; COM’REPEATOPT := COM’NFOPT := NORM; END; << DELETEKEY: >> BEGIN DIRECTION := FORWARDS; COM’DELETEFLAG := TRUE; VWRITEBATCH (COMAREA); CHECK’ERROR; COM’DELETEFLAG := FALSE; IF NOT ERRORS THEN COM’RECNUM := COM’RECNUM + 1D; COM’REPEATOPT := COM’NFOPT := NORM; END; << PRINTKEY: >> BEGIN VPRINTFORM (COMAREA,
-
SAMPLE PROGRAMS SPL COM’SHOWCONTROL.
-
SAMPLE PROGRAMS SPL $PAGE " COLLECT" <<****************************************************************>> << >> << COLLECT >> << >> <<****************************************************************>> PROCEDURE COLLECT; BEGIN LOGICAL FIRST’TIME := TRUE ; BYTE ARRAY SAVED’FORM’NAME (0:NAMELEN-1) ; DO’COLLECT’LABELS; COM’MODE := COLLECT’MODE; COM’DELETEFLAG := FALSE; DO << UNTIL COM’NFNAME <> EXIT AND COM’DO <> NORM >> BEGIN IF COM’LASTKEY=ENTERKEY OR COM’LASTKEY=NEXTKEY THEN IF COM’REPEATOPT=NOREPEAT AND
-
SAMPLE PROGRAMS SPL ERRORS := FALSE; VSHOWFORM (COMAREA); CHECK’ERROR; COM’SHOWCONTROL := 0; << CLEAR >> IF COM’DBUFLEN <= 0 AND << DONT READ!!! >> COM’REPEATOPT=NOREPEAT AND COM’NFOPT <> NORM THEN BEGIN IF NOT ERRORS AND BATCH THEN BEGIN VWRITEBATCH (COMAREA).
-
SAMPLE PROGRAMS SPL END; END; END; END; << HEADKEY: >> BEGIN COM’REPEATOPT := NORM; COM’NFOPT := NORM; MOVE COM’NFNAME := "$HEAD END; "; << DELETEKEY: >> ENTRY’ERROR (DELETE’NOT’DEFINED); << PRINTKEY: >> BEGIN VPRINTFORM (COMAREA, UNDERLINE, PAGE’EJECT); CHECK’ERROR; END; << REFRESHKEY: >> MOVE COM’NFNAME := "$REFRESH "; << PREVKEY: >> ENTRY’ERROR (PREV’NOT’ALLOWED); << NEXTKEY: >> BEGIN IF COM’REPEATOPT = NORM THEN ENTRY’ERROR (NOT’REPEATING) ELSE COM’REPEATOPT := NORM; END; << BROWSEKEY: >> BEGIN IF N
-
SAMPLE PROGRAMS SPL COM’RECNUM := LAST’REC’NUM; COM’REPEATOPT := COM’NFOPT := NORM; COM’DELETEFLAG := FALSE; << IF NO RECS >> IF COM’LASTKEY = EXITKEY THEN BEGIN MOVE COM’CFNAME := SAVED’FORM’NAME,(NAMELEN); RETURN; END; DO’COLLECT’LABELS; END; END; << BROWSEKEY >> << EXIT: >> RETURN; END; << CASE COM’LASTKEY >> END; << IS COM’DBUFLEN > O? >> END UNTIL NOT ERRORS AND COM’LASTKEY <> PRINTKEY; END UNTIL COM’NFNAME = "$END COM’REPEATOPT = NORM; END; 430 " AND << COLLECT >> Appendix A
-
SAMPLE PROGRAMS SPL $PAGE " ENTRY OUTER BLOCK" <<****************************************************************>> << >> << OUTER BLOCK >> << >> <<****************************************************************>> INTRINSIC PRINT; << FOR ID MESSAGE >> << FOR INTERNAL TESTING ONLY >> INIT; COLLECT; EXIT; END.
-
SAMPLE PROGRAMS COBOL COBOL $CONTROL LIST, MAP, VERBS IDENTIFICATION DIVISION. PROGRAM-ID. COBOL-EXAMPLE. ***** ***** ***** ***** ***** ***** ***** ***** ***** ***** ***** ***** ***** ***** ***** ***** ***** ***** This application collects employee payroll deduction transactions and places the edited transactions into a file. For this application: Enter key = edit and file transaction; f8 = exit application; all other f keys = redo transaction.
-
SAMPLE PROGRAMS COBOL 01 05 WINDOWENH 05 MULTIUSAGE 05 LABELOPTIONS 05 CFNAME 05 NFNAME 05 REPEATAPP 05 FREEZEAPP 05 CFNUMLINES 05 DBUFLEN 05 FILLER 05 LOOKAHEAD 05 DELETEFLAG 05 SHOWCONTROL 05 FILLER 05 PRINTFILENUM 05 FILERRNUM 05 ERRFILENUM 05 FORMSTORESIZE 05 FILLER 05 FILLER 05 FILLER 05 NUMRECS 05 RECNUM 05 FILLER 05 FILLER 05 TERMFILEN 05 FILLER 05 FILLER 05 FILLER 05 FILLER 05 FILLER 05 RETRIES 05 TERMOPTIONS 05 ENVIRON 05 USERTIME 05 IDENTIFIER 05 LABELINFO FIELDINFO.
-
SAMPLE PROGRAMS COBOL 01 ERROR-LOCATION PIC X(70). 01 FILENAME PIC X(86). 01 FOUND-DATA-ERRORS PIC X. 01 INFOBUFLEN PIC S9(4) COMP. 01 MSGBUF PIC X(150). 01 MSGBUFLEN PIC S9(4) COMP. 01 ERRMSGLEN PIC S9(4) COMP. 01 NBR-TXN-COLLECTED PIC 9(4). 01 NUMSPECS PIC S9(4) COMP. 01 STOP-NOW PROCEDURE DIVISION. PIC X. A-000-START-PROGRAM. MOVE "N" TO STOP-NOW DONE-WITH-TRANSACTIONS. MOVE ZERO TO NBR-TXN-COLLECTED. PERFORM A-100-SETUP-FOR-WORK.
-
SAMPLE PROGRAMS COBOL ***** ***** ***** Set Comarealen to 60 words (120 bytes). MOVE 60 TO COMAREALEN OF COMAREA. ***** ***** ***** Activate function key labeling. MOVE 1 TO LABELOPTIONS OF COMAREA. ***** ***** ***** Disable form background loading on Vreadfields. MOVE ZERO TO LOOKAHEAD OF COMAREA. ***** ***** ***** Set size of local form storage directory. MOVE 4 TO FORMSTORESIZE OF COMAREA. ***** ***** Open the Transaction File ***** OPEN OUTPUT TXN-ENTRY. ***** ***** Open the Forms File.
-
SAMPLE PROGRAMS COBOL MOVE "Y" TO STOP-NOW MOVE "**** Paragraph: A-100-SETUP-FOR-WORK - Terminal Setu "p" TO ERROR-LOCATION PERFORM Z-100-GET-ERROR-MESSAGE. IF STOP-NOW NOT = "Y" ***** ***** Translate field names to screen orders. ***** ***** Three of the fields in the form used by this ***** application need to be toggled from "display ***** only" to "input allowed". In order to do this, ***** we first translate field names to screen orders.
-
SAMPLE PROGRAMS COBOL MOVE "**** Paragraph: A-100-SETUP-FOR-WORK - Field Informa "tion Retrieval" TO ERROR-LOCATION PERFORM Z-100-GET-ERROR-MESSAGE. A-500-COLLECT-TRANSACTIONS. ***** ***** Setup for and get transaction data entry form. ***** MOVE ZERO TO REPEATAPP OF COMAREA FREEZEAPP OF COMAREA. MOVE "DEDUCTION" TO NFNAME OF COMAREA. CALL "VGETNEXTFORM" USING COMAREA.
-
SAMPLE PROGRAMS COBOL MOVE 3 TO NUMSPECS CALL "VCHANGEFIELD" USTNG COMAREA FIELDSPES NUMSPECS IF CSTATUS OF COMAREA NOT = 0 MOVE "Y" TO STOP-NOW MOVE "**** Paragraph: A-500-COLLECT-TRANSACTIONS - Field "Type Updates" TO ERROR-LOCATION PERFORM Z-100-GET-ERROR-MESSAGE. IF STOP-NOW NOT = "Y" ***** ***** Load window message. ***** MOVE 79 TO MSGBUFLEN MOVE "Fill in Deduction Transaction according to worksheet.
-
SAMPLE PROGRAMS COBOL ***** Show form. ***** CALL "VSHOWFORM" USING COMAREA IF CSTATUS OF COMAREA NOT = 0 MOVE "Y" TO STOP-NOW MOVE "**** Paragraph: A-500-COLLECT-TRANSACTIONS - Form D "isplay" TO ERROR-LOCATION PERFORM Z-100-GET-ERROR-MESSAGE. IF STOP-NOW NOT = "Y" ***** ***** Setup and loop on transaction until it can be filed. ***** MOVE "Y" TO FOUND-DATA-ERRORS PERFORM B-100-READ-EDIT-AND-FILE UNTIL FOUND-DATA-ERRORS = "N" OR STOP-NOW = "Y" OR DONE-WITH-TRANSACTIONS = "Y". B-100-READ-EDIT-AND-FILE.
-
SAMPLE PROGRAMS COBOL IF CSTATUS OF COMAREA NOT = 0 MOVE "Y" TO STOP-NOW MOVE "**** Paragraph: B-100-READ-EDIT-AND-FILE - Data Edit " " TO ERROR-LOCATION PERFORM Z-100-GET-ERROR-MESSAGE ELSE ***** ***** Determine if edit errors detected. ***** IF NUMERRS OF COMAREA < 1 MOVE "N" TO FOUND-DATA-ERRORS. IF STOP-NOW NOT = "Y" AND DONE-WITH-TRANSACTIONS NOT = "Y" AND FOUND-DATA-ERRORS NOT = "Y" ***** ***** Finish form data.
-
SAMPLE PROGRAMS COBOL ***** MOVE SPACES TO DATABUF MOVE 200 TO DATABUFLEN CALL "VGETBUFFER" USING COMAREA DATABUF DATABUFLEN IF CSTATUS OF COMAREA NOT = 0 MOVE "Y" TO STOP-NOW MOVE "**** Paragraph: B-100-READ-EDIT-AND-FILE - Dat "a Get" TO ERROR-LOCATION PERFORM Z-100-GET-ERROR-MESSAGE ELSE WRITE TXN-REC FROM DATABUF ADD 1 TO NBR-TXN-COLLECTED.
-
SAMPLE PROGRAMS COBOL ***** Get message text associated with first field flagged ***** with a data error. ***** PERFORM Z-100-GET-ERROR-MESSAGE. CALL "VPUTWINDOW" USING COMAREA MSGBUF ERRMSGLEN. IF CSTATUS OF COMAREA NOT = 0 MOVE "Y" TO STOP-NOW MOVE "**** Paragraph: B-200-PROMPT-OPERATOR - Window Load" TO ERROR-LOCATION PERFORM Z-100-GET-ERROR-MESSAGE. IF STOP-NOW NOT = "Y" ***** ***** Display highlighted form and updated window message. ***** CALL "VSHOWFORM" USING COMAREA.
-
SAMPLE PROGRAMS COBOL ERRMSGLEN Z-900-DISPLAY-SYSTEM-ERROR. DISPLAY "**** Transaction entry facility detected system erro "r at:". DISPLAY ERROR-LOCATION. DISPLAY "**** The error message returned is:". DISPLAY "**** " MSGBUF.
-
SAMPLE PROGRAMS FORTRAN 77 FORTRAN 77 $CONTROL list on, tables on ! ! This application collects employee payroll deduction ! transactions and places the edited transactions into ! a file. ! ! For this application: Enter key = edit and file ! transaction; ! ! ! ! ! ! ! ! ! ! ! f8 = exit application; all other f keys = redo transaction. Each transaction entered by the operator is subjected to the data edits embedded within the input form.
-
SAMPLE PROGRAMS FORTRAN 77 INTEGER*2 INTEGER*2 CHARACTER*70 MSGBUFLEN ERRMSGLEN ERROR_LOCATION ! STOP_ NOW = 0 DONE_ WITH_TXNS = 0 ! NBR_TXN_COLLECTED = 0 ! CALL SETUP_FOR_WORK ! DO WHILE (STOP NOW.EQ.0 + .AND.DONE_WITH_TXNS.EQ.0) CALL COLLECT_TXNS END DO ! CALL CLEANUP_AFTER _ WORK ! PRINT *, + "Deduction transactions collected this session =", + NBR_TXN_COLLECTED ! IF (STOP NOW.EQ.
-
SAMPLE PROGRAMS FORTRAN 77 $TITLE ’ Setup For Work’ !***************************************************************! ! ! ! Setup For Work ! ! ! !***************************************************************! ! SUBROUTINE SETUP-FOR -WORK ! IMPLICIT NONE ! COMMON /COMO1/ COMAREA COMMON /COMll/ STOP_NOW COMMON /COM21/ FIELDINFO COMMON /COM22/ INFOBUFLEN COMMON /COM81/ MSGBUF COMMON /COM82/ MSGBUFLEN COMMON /COM83/ ERRMSGLEN COMMON /COM91/ ERROR_LOCATION ! SYSTEM INTRINSIC VOPENFORMF, + VOPENTERM, + VGETFI
-
SAMPLE PROGRAMS FORTRAN 77 ! ! Init Comarea to all zeros. ! ARRAY_INDEX = 1 DO WHILE (ARRAY_INDEX.LE.60) COMAREA(ARRAY_INDEX) = 0 ARRAY_INDEX = ARRAY_INDEX + 1 END DO ! ! Set Language for FORTRAN-77. ! LANGUAGE = 5 ! ! Set Comarealen for 60 words (120 bytes). ! COMAREALEN = 60 ! ! Activate function key labeling. ! LABELOPTIONS = 1 ! ! Disable form background loading on Vreadfields. ! LOOKAHEAD = 0 ! ! Set size of local form storage directory.
-
SAMPLE PROGRAMS FORTRAN 77 + "**** Routine: Setup For Work - Forms File Open" CALL GET_ERROR_MESSAGE END IF END IF ! ! Open the Terminal. ! IF (STOP NOW.EQ.0) THEN FILENAME = "HPTERM" ! CALL VOPENTERM (COMAREA, + FILENAME) ! IF (CSTATUS.NE.0) THEN STOP_NOW = 1 ERROR_LOCATION = + "**** Routine: Setup For Work - Terminal Setup" CALL GET_ERROR_MESSAGE END IF END IF ! ! Translate field names to screen orders.
-
SAMPLE PROGRAMS FORTRAN 77 ERROR_LOCATION = "**** Routine: Setup For Work - Field Info Retrieval" CALL GET_ERROR_MESSAGE END IF END IF + ! END Appendix A 449
-
SAMPLE PROGRAMS FORTRAN 77 $TITLE ’ Collect Transactions’ !***************************************************************! ! ! ! Collect Transactions ! ! ! !***************************************************************! ! SUBROUTINE COLLECT_TXNS ! IMPLICIT NONE ! COMMON COMMON COMMON COMMON COMMON COMMON COMMON COMMON COMMON COMMON /COMO1/ /COMll/ /COM12/ /COMI3/ /COM21/ /COM81/ /COM82/ /COM83/ /COM91/ /COM101/ COMAREA STOP_NOW DONE_WITH_TXNS NBR_TXN_COLLECTED FIELDINFO MSGBUF MSGBUFLEN ERRMSGLEN ERROR
-
SAMPLE PROGRAMS FORTRAN 77 INTEGER*2 CHANGE_TYPE(4,3) CHARACTER*4 CHANGE_SPEC(2,3) EQUIVALENCE (FIELDSPECS (1), FIELD_ID) , + (FIELDSPECS (1), CHANGE_TYPE), + (FIELDSPECS (1), CHANGE_SPEC) INTEGER*2 NUMSPECS INTEGER*2 FOUND_DATA_ERRS ! ! Setup for and get transaction data entry form. ! REPEATAPP = 0 FREEZEAPP = 0 ! NFNAME = "DEDUCTION" ! CALL VGETNEXTFORM (COMAREA) ! IF (CSTATUS.NE.
-
SAMPLE PROGRAMS FORTRAN 77 CALL GET_ERROR_MESSAGE END IF END IF ! ! Load window message. ! IF (STOP_NOW.EQ.0) THEN ! MSGBUFLEN = 79 ! MSGBUF = + "Fill in Deduction Transaction according to worksheet." ! CALL VPUTWINDOW (COMAREA, + MSGBUF, + MSGBUFLEN) ! IF (CSTATUS.NE.0) THEN STOP_NOW = 1 ERROR_LOCATION = + "**** Routine: Collect Transactions - Window Load" CALL GET_ERROR_MESSAGE END IF END IF ! ! Initialize form. ! IF (STOP_NOW.EQ.0) THEN ! CALL VINITFORM (COMAREA) ! IF (CSTATUS.NE.
-
SAMPLE PROGRAMS FORTRAN 77 DO WHILE (FOUND_DATA_ERRS.EQ.1 + .AND.STOP_NOW.EQ.0 + .AND.DONE_WITH_TXNS.EQ.
-
SAMPLE PROGRAMS FORTRAN 77 $TITLE ’ Read Edit and File’ !***************************************************************! ! ! ! Read Edit and File ! ! ! !***************************************************************! ! SUBROUTINE READ_EDIT_AND_FILE ! IMPLICIT NONE ! COMMON /COMO1/ COMAREA COMMON /COMll/ STOP_NOW COMMON /COM12/ DONE_WITH_TXNS COMMON /COM13/ NBR_TXN_COLLECTED COMMON /COM81/ MSGBUF COMMON /COM82/ MSGBUFLEN COMMON /COM83/ ERRMSGLEN COMMON /COM91/ ERROR_LOCATION COMMON /COM101/ FOUND_DATA_ER
-
SAMPLE PROGRAMS FORTRAN 77 IF (STOP NOW.EQ.0) THEN IF (LASTKEY.EQ.8) THEN DONE_WITH_TXNS = 1 END IF END IF ! ! Edit data read from terminal. ! IF (STOP_NOW.EQ.0 + .AND.DONE_WITH_TXNS.EQ.0) THEN ! CALL VFIELDED (COMAREA) ! IF (CSTATUS.NE.0) THEN STOP_NOW = 1 ERROR_LOCATION = + "**** Routine: Read Edit and File - Data Edit" CALL GET_ERROR_MESSAGE END IF END IF ! ! Determine if edit errors detected. ! IF (STOP_NOW.EQ.0 + .AND.DONE_WITH_TXNS.EQ.0) THEN ! IF (NUMERRS.LT.
-
SAMPLE PROGRAMS FORTRAN 77 ! ! Do we have a transaction that can be filed? ! IF (STOP_NOW.EQ.0 + .AND.DONE_WITH_TXNS.EQ.0) THEN ! IF (FOUND_DATA_ERRS.EQ.0 + .AND.LASTKEY.EQ.0) THEN ! ! Get transaction from form and file it. ! DATABUF = " " ! DATABUFLEN = 200 ! CALLVGETBUFFER (COMAREA, + DATABUF, + DATABUFLEN) ! IF (CSTATUS.NE.0) THEN STOP NOW = 1 ERROR_LOCATION = + "**** Routine: Read Edit and File - Data Get" CALL GET_ERROR_MESSAGE ! ELSE ! ! Write Databuf to Transaction File.
-
SAMPLE PROGRAMS FORTRAN 77 ENDIF ! ! Do we need to refresh the display? ! IF (STOP_ NOW.EQ.0 + .AND.DONE_WITH_TXNS.EQ.0) THEN ! IF (FOUND_DATA_ERRS.EQ.1 + .AND.LASTKEY.NE.0) THEN ! ! The operator pressed some key other than ! or so clear data error flag to break loop.
-
SAMPLE PROGRAMS FORTRAN 77 $TITLE ’ Prompt Operator’ !***************************************************************! ! ! ! Prompt Operator ! ! ! !***************************************************************! ! SUBROUTINE PROMPT_OPERATOR ! IMPLICIT NONE ! COMMON /COMO1/ COMAREA COMMON /COM11/ STOP NOW COMMON /COM81/ MSGBUF COMMON /COM82/ MSGBUFLEN COMMON /COM83/ ERRMSGLEN COMMON /COM91/ ERROR_LOCATION ! SYSTEM INTRINSIC VPUTWINDOW, + VSHOWFORM ! INTEGER*2 COMAREA(60) INTEGER*2 CSTATUS EQUIVALENCE (COM
-
SAMPLE PROGRAMS FORTRAN 77 END IF END IF ! END Appendix A 459
-
SAMPLE PROGRAMS FORTRAN 77 $TITLE ’ Cleanup After Work’ !***************************************************************! ! ! ! Cleanup After Work ! ! ! !***************************************************************! ! SUBROUTINE CLEANUP_AFTER_WORK ! IMPLICIT NONE ! COMMON /COMO1/ COMAREA ! SYSTEM INTRINSIC VCLOSEFORMF, + VCLOSETERM ! INTEGER*2 COMAREA(60) INTEGER*2 CSTATUS EQUIVALENCE (COMAREA(1), CSTATUS) ! ! Note that this routine unconditionally attempts to close ! the Forms File and Terminal ! CLOS
-
SAMPLE PROGRAMS FORTRAN 77 $TITLE ’ Get Error Message’ !***************************************************************! ! ! ! Get Error Message ! ! ! !***************************************************************! ! SUBROUTINE GET-ERROR-MESSAGE ! IMPLICIT NONE ! COMMON /COMO1/ COMAREA COMMON /COM81/ MSGBUF COMMON /COM82/ MSGBUFLEN COMMON /COM83/ ERRMSGLEN ! SYSTEM INTRINSIC VERRMSG ! INTEGER*2 COMAREA(60) CHARACTER*150 MSGBUF INTEGER*2 MSGBUFLEN INTEGER*2 ERRMSGLEN ! MSGBUF = " " MSGBUFLEN = 150 ! CALL
-
SAMPLE PROGRAMS FORTRAN 77 $TITLE ’ Display System Error’ !***************************************************************! ! ! ! Display System Error ! ! ! !***************************************************************! ! SUBROUTINE DISPLAY_SYSTEM_ERROR ! IMPLICIT NONE ! COMMON /COM81/ MSGBUF COMMON /COM91/ ERROR_LOCATION ! CHARACTER*150 MSGBUF CHARACTER*70 ERROR_LOCATION ! PRINT *, + "**** Transaction entry facility detected system error at:" PRINT *, ERROR_LOCATION PRINT *, + "**** The error message
-
SAMPLE PROGRAMS BASIC BASIC 60 65 70 75 80 85 90 95 100 105 110 115 120 125 130 135 140 145 150 155 160 165 170 175 180 185 190 195 200 205 210 220 225 230 235 240 245 250 255 260 265 270 275 280 285 295 300 305 310 315 320 325 330 335 REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM REM This program controls source data entry for any forms fil
-
SAMPLE PROGRAMS BASIC 340 REM C(19:26) - name of next form (packed) 345 REM C(27) - Repeat option 350 REM C(28) - NF option 355 REM C(29) - not used 360 REM C(30) - Length of data buffer 365 REM C(31) - not used 370 REM C(33) - Delete flag 375 REM C(34) - Show control 80 REM C(35:42) - not used 385 REM C(43:44) - Number of recs in batch file (double)* 390 REM C(45:46) - Record # in batch file (double)* 395 REM C(47,48) - not used 400 REM C(49) - Terminal file # 405 REM C(56) - Terminal options 410 REM 415 R
-
SAMPLE PROGRAMS BASIC 2140 2150 2160 2170 2180 2190 2200 2210 2220 2230 2240 2250 2260 2270 2280 2290 2300 2305 2310 2315 2320 2330 2340 2350 2360 2370 2380 2390 2400 2410 2420 2430 2440 2450 2460 2470 2480 2490 2500 2510 2520 2530 2540 2550 3000 3005 3010 3015 3020 3025 3030 3035 3040 3045 3050 3055 3060 3065 IF NOT LEN(U$) THEN 9900 U$=U$+" " CALL VOPENFORMF(C[*],U$) IF C[1] THEN DO GOSUB 9000 GOTO 2100 DOEND REM1 *OPEN BATCH FILE* PRINT " Enter BATCH file name and press RETURN: "; LINPUT U$ IF NOT LEN(U
-
SAMPLE PROGRAMS BASIC 3070 3075 3080 3085 3090 3095 3100 3105 3110 3115 3120 3125 3130 3132 3135 3140 3145 3146 3147 3148 3149 3150 3151 3152 3155 3160 3165 3170 3175 3180 3185 3190 3195 3200 3205 3300 3305 3310 3315 3320 3325 3330 3335 3340 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3355 3360 3365 3370 466 RETURN DOEND IF C[1] THEN GOSUB 9100 F1=0 CALL VINITFORM(C[*]) IF C[1] OR C[7] THEN GOSUB 9100 IF NOT E THEN GOSUB 8000 REM1 *SOFTKEY LOOP* E=O CALL VSHOWFORM(C[*]) IF C[1] THEN GOSUB 9100 C[34]
-
SAMPLE PROGRAMS BASIC 3400 3410 3420 3430 3450 3455 3460 3465 3470 3475 3500 3505 3510 3515 3550 3555 3560 3565 3600 3610 3620 3630 3640 3650 3660 3700 3710 3720 3730 3740 3750 3760 3770 3780 3790 3800 3810 3820 3830 3840 3850 3860 3870 3880 3890 3900 3910 3920 3921 3922 3923 3930 3940 3950 4000 4005 4010 4015 REM1 E$="DELETE key defined only for BROWSE" GOSUB 9200 RETURN REM1 I=1 J=49 CALL VPRINTFORM(C[*],I,J) IF C[1] THEN GOSUB 9100 RETURN REM1 B1$="$REFRESH" GOSUB
-
SAMPLE PROGRAMS BASIC 4020 4025 4030 4035 4040 4045 4050 4055 4060 4065 4070 4075 4080 4085 4090 4095 4100 4105 4110 4115 4120 4125 4130 4135 4140 4145 4150 4155 4160 4165 4170 4175 4180 4185 4190 4195 4200 4205 4210 4215 4220 4225 4230 4235 4240 4245 4250 4255 4300 4305 4310 4315 4320 4325 4330 4335 4340 4345 468 REM1 *BROWSE UNTIL EXIT OR COLLECT KEY* IF NOT C[44] THEN RETURN IF C[46]=R1 THEN DO E$=" There are no more batch records.
-
SAMPLE PROGRAMS BASIC 4350 4355 4360 4365 4370 4375 4380 4385 4400 4410 4420 4450 4455 4460 4465 4470 4475 4480 4485 4490 4500 4505 4510 4515 4520 4525 4550 4560 4600 4610 4620 4630 4650 4655 4660 4665 4670 4675 4680 4685 5000 5010 5020 5030 5040 5050 5060 5070 5080 5090 5100 5110 5120 5130 5140 5150 5160 5170 DOEND IF NOT E THEN DO CALL VWRITEBATCH(C[*]) IF C[1] THEN GOSUB 9100 IF NOT E THEN C[46]=C[46]+1 DOEND DOEND RETURN REM1
D1=C[27]=C[28]=C[46]=0 RETURN REM1 D1=0 C[33]=1 CALL
-
SAMPLE PROGRAMS BASIC 5180 8000 8010 8020 8030 8040 8050 8060 8070 8080 8100 8110 8120 8130 8140 8150 8160 8170 8180 8200 8210 8220 8230 8240 8250 8260 9000 9020 9030 9040 9100 9105 9110 9125 9130 9135 9140 9145 9150 9200 9210 9220 9230 9240 9250 9900 9910 9920 470 RETURN REM2 S$=" ENTRY "+V$+’27"&a31CBATCH RECORD # " CONVERT C[46]+1 TO S$[LEN(S$)+1] S$=S$+’27"&a65CMODE: " IF NOT C[5] THEN S$=S$+"COLLECT" ELSE S$=S$+’27"&dKBROWSE" I=LEN(S$) CALL VPUTWINDOW(C[*],S$,I) RETURN REM2
-
SAMPLE PROGRAMS TRANSACT TRANSACT SYSTEM TRANS,ENTITY =TXNFILE(APPEND); << This application collects employee payroll deduction transactions and places the edited transactions into a file. For this application: Enter key = edit and file transaction; f8 = exit application; all other f keys = redo transaction. Each transaction entered by the operator is subjected to the data edits embedded within the input form.
-
SAMPLE PROGRAMS TRANSACT DATABUFLEN I(4): DONE-WITH-TRANS I(4): ERROR-LOCATION X(70): FIELDINFO X(80): NUM-ENTRIES I(4)=FIELDINFO: ENTRY-LEN I(4)=FIELDINFO(3): FORM-NAME X(16)=FIELDINFO(5): FIELDDATA 3 X(20)=FIELDINFO(21): FIELDENTRY X(20)=FIELDDATA: FIELD-NAME X(16)=FIELDENTRY: SCREEN-ORDER I(4)=FIELDENTRY(17): FIELD-NUM I(4)=FIELDENTRY(19): FIELDSPECS-ITEM 3 X(8): FIELDSPECS X(8)=FIELDSPECS-ITEM: FIELD-ID I(4)=FIELDSPECS: CHANGE-TYPE I(4)=FIELDSPECS(3): CHANGE-SPEC X(4)=FIELDSPECS(5): FILENAME X(86): FOUN
-
SAMPLE PROGRAMS TRANSACT IF (STOP-NOW) = (TRUE) THEN END(LEVEL) ELSE IF (DONE-WITH-TRANS) = (TRUE) THEN END(LEVEL) ELSE DO PERFORM COLLECT-TRANSACTIONS; END; <> DOEND; PERFORM CLEANUP-AFTER-WORK; DISPLAY "Deduction transactions collected this sesion =": NBR-TXN-COLLECT; IF (STOP-NOW) = (TRUE) THEN PERFORM DISPLAY-SYSTEM-ERROR; EXIT; DISPLAY-SYSTEM-ERROR: <<*****************>> DISPLAY "**** Transaction collection facility detected system " "error at: ": ERROR-LOCATION: "**** The err
-
SAMPLE PROGRAMS TRANSACT DOEND; PROC VSHOWFORM((COMAREA)); IF (CSTATUS) <> (ZERO) THEN DO LET (STOP-NOW) = (TRUE); MOVE (ERROR-LOCATION) = "**** procedure: Collect Transactions" " - Display Update"; PERFORM GET-ERROR-MESSAGE; DOEND; RETURN; READ-EDIT-FILE-TRANSACTION: <<***********************>> PROC VREADFIELDS((COMAREA)); IF (CSTATUS) <> (ZERO) THEN DO LET (STOP-NOW) = (TRUE); MOVE (ERROR-LOCATION) = "**** procedure: Read, Edit, and File" " - Terminal Read"; PERFORM GET-ERROR-MESSAGE; RETURN; DOEND; << De
-
SAMPLE PROGRAMS TRANSACT LET (FOUND-DATA-ERRS) = (FALSE); IF (FOUND-DATA-ERRS) = (FALSE) THEN DO << Finish form data >> PROC VFINISHFORM((COMAREA)); IF (CSTATUS) <> (ZERO) THEN DO LET (STOP-NOW) = (TRUE); MOVE (ERROR-LOCATION) = "**** procedure: Read, Edit," " and File - Data Finishing"; PERFORM GET-ERROR-MESSAGE; RETURN; DOEND; IF (NUMERRS) > (ZERO) THEN LET (FOUND-DATA-ERRS) = (TRUE); DOEND; << Finish form data >> << Do we have a transaction that can be filed? >> IF (FOUND-DATA-ERRS) = (FALSE) THEN DO <<
-
SAMPLE PROGRAMS TRANSACT LET (STOP-NOW) = (TRUE); MOVE (ERROR-LOCATION) = "**** procedure: Collect Transactions" " - Form Retrieval"; PERFORM GET-ERROR-MESSAGE; RETURN; DOEND; << Toggle three fields in form to "input allowed" >> << Screen order is indicated to field change intrinsic as negative number LET OFFSET(FIELDSPECS) = 0; LET OFFSET(FIELDENTRY) = 0; LET (FIELD-ID) = (SCREEN-ORDER) * [-1]; LET (CHANGE-TYPE) = 5; MOVE (CHANGE-SPEC) = "O"; LET OFFSET(FIELDSPECS) = 8; LET OFFSET(FIELDENTRY) = 20; LET (FI
-
SAMPLE PROGRAMS TRANSACT PROC VINITFORM((COMAREA)); IF (CSTATUS) <> (ZERO) THEN DO LET (STOP-NOW) = (TRUE); MOVE (ERROR-LOCATION) = "**** procedure: Collect Transactions" " - Form Init"; PERFORM GET-ERROR-MESSAGE; RETURN; DOEND; << Show form >> PROC VSHOWFORM((COMAREA)); IF (CSTATUS) <> (ZERO) THEN DO LET (STOP-NOW) = (TRUE); MOVE (ERROR-LOCATION) = "**** procedure: Collect Transactions" " - Form Display"; PERFORM GET-ERROR-MESSAGE; RETURN; DOEND; << Setup and loop on transaction until it can be filed >> LE
-
SAMPLE PROGRAMS TRANSACT LET (LABELOPTIONS) = 1; MOVE (CFNAME) = " "; MOVE (NFNAME) = " "; LET (FORMSTORESIZE) = 4; << Open of Transaction file done in SYSTEM statement. Opened so that new records are appended to those already in the file >> << Open forms file >> MOVE (FILENAME) = "PAYROLL.VPLUS.
-
SAMPLE PROGRAMS TRANSACT LET (INFOBUFLEN) = (NUM-ENTRIES) * (ENTRY-LEN) + 10; PROC VGETFIELDINFOR((COMAEA),(FIELDINFO),(INFORBUFLEN)); IF (CSTATUS) <> (ZERO) THEN DO LET (STOP-NOW) = (TRUE); MOVE (ERROR-LOCATION) = "**** procedure: Setup For Work - " "Field Info Retrieval"; PERFORM GET-ERROR-MESSAGE; DOEND; RETURN; Appendix A 479
-
SAMPLE PROGRAMS PASCAL PASCAL $TITLE ’VPLUS/V Data Entry Sample Program’$ { This application collects employee payroll deduction transactions and places the edited transactions into a file. For this application: Enter key = edit and file transaction; f8 = exit application; all other f keys = redo transaction. Each transaction entered by the operator is subjected to the data edits embedded within the input form.
-
SAMPLE PROGRAMS PASCAL NFNAME REPEATAPP FREEZEAPP CFNUMLINES DBUFLEN SKIP_31 LOOKAHEAD DELETEFLAG SHOWCONTROL SKIP_35 PRINTFILENUM FILERRNUM ERRFILENUM FORMSTORESIZE SKIP_40 SKIP_41 SKIP_42 NUMRECS RECNUM SKIP_47 SKIP_48 TERM_FILEN SKIP 50 SKIP_51 SKIP_52 SKIP_53 SKIP_54 RETRIES TERM_OPTIONS ENVIRON USERTIME IDENTIFIER LABELINFO END; : PAC_16; : SMALL_INT; : SMALL_INT; : SMALL_INT; : SMALL_INT; : SMALL_INT; : SMALL_INT; : SMALL_INT; : SMALL_INT; : SMALL_INT; : SMALL_INT; : SMALL_INT; : SMALL_INT; : SMALL_
-
SAMPLE PROGRAMS PASCAL { Comarea initialization constant record } COMAREA_INIT = COMAREA REC [ CSTATUS : 0, LANGUAGE : 5, {Pascal } COMAREALEN :60, USERBUFLEN : 0, CMODE : 0, LASTKEY : 0, NUMERRS : 0, WINDOWENH : 0, MULTIUSAGE : 0, LABELOPTIONS : 1, {activate labels} CFNAME : ’’, NFNAME : ’’, REPEATAPP : 0, FREEZEAPP : 0, CFNUMLINES : 0, DBUFLEN : 0, SKIP_31 : 0, LOOKAHEAD : 0, {no form background loading} DELETEFLAG : 0, SHOWCONTROL : 0, SKIP_35 : 0, PRINTFILENUM : 0, FILERRNUM : 0, ERRFILENUM : 0, FORMSTO
-
SAMPLE PROGRAMS PASCAL INFOBUFLEN MSGBUF MSGBUFLEN ERRMSGLEN NBR_TXN_COLLECTED NUMSPECS STOP_NOW TXN_FILE : : : : : : : : SMALL_INT; PAC MAXWINDOWLEN; SMALL_INT; SMALL_INT; INTEGER; SMALL_INT; BOOLEAN; TEXT; { Procedure Declarations } PROCEDURE PROCEDURE PROCEDURE PROCEDURE PROCEDURE PROCEDURE PROCEDURE PROCEDURE PROCEDURE PROCEDURE PROCEDURE PROCEDURE PROCEDURE PROCEDURE PROCEDURE VCHANGEFIELD VCLOSEFORMF VCLOSETERM VERRMSG VFIELDEDITS VFINISHFORM VGETBUFFER VGETFIELDINFO VGETNEXTFORM VINITFORM VOPENFO
-
SAMPLE PROGRAMS PASCAL END; PROCEDURE GET_ERROR_MESSAGE; BEGIN MSGBUFLEN := MAXWINDOWLEN; VERRMSG (COMAREA, MSGBUF, MSGBUFLEN, ERRMSGLEN); END; PROCEDURE PROMPT_OPERATOR; BEGIN GET_ERROR_MESSAGE; VPUTWINDOW (COMAREA, MSGBUF, ERRMSGLEN); IF COMAREA.CSTATUS <> 0 THEN BEGIN STOP_ NOW := TRUE; ERROR_LOCATION := ’**** procedure: Prompt Operator - Window Load’; GET ERROR_MESSAGE; END; IF NOT (STOP_NOW) THEN BEGIN { Display update } VSHOWFORM {COMAREA}; IF COMAREA.
-
SAMPLE PROGRAMS PASCAL END; END; { Procedure Collect Transactions } PROCEDURE SETUP_FOR_WORK; BEGIN { Init Comarea } COMAREA := COMAREA_INIT; { Open Transaction File so that new transactions are added to those already in the file } APPEND (TXN_FILE, ’PAYTXN’); { Open forms file } FILENAME := ’PAYROLL.WORK.ADMIN’; VOPENFORMF (COMAREA, FILENAME); IF COMAREA.
-
SAMPLE PROGRAMS PASCAL { Three of the fields in the form used by this application need to be toggled from "display only" to "input allowed". In order to do this, we first translate field names to screen orders. } { Setup to retrieve screen order for three specified fields } FIELDINFO.NUM_ENTRIES := 3; FIELDINFO.ENTRY_LEN := 9; { Field name key and screen order } FIELDINFO.FORM_NAME := ’DEDUCTION’; FIELDINFO.FIELDENTRY [1].FIELD_NAME := ’BADGE_NUMBER’; FIELDINFO.FIELDENTRY [1].
-
SAMPLE PROGRAMS PASCAL CLEANUP_AFTER_WORK; WRITELN (’Deduction transactions collected this session = ’, NBR_TXN_COLLECTED); IF STOP NOW THEN DISPLAY_SYSTEM_ERROR; END.
-
SAMPLE PROGRAMS PASCAL 488 Appendix A
-
VPLUS Error Messages B VPLUS Error Messages Note the following words or characters within messages: This appendix lists all error messages that can occur during execution of VPLUS in interactive mode or batch mode. The messages consist of the error number and the associated message. Cause and action text is provided for most messages. • FSERR Indicates a file system error has occurred. When the number following FSERR is negative, refer to the appropriate group (FORMSPEC, REFSPEC, etc.
-
VPLUS Error Messages Classification of Error Messages Classification of Error Messages VPLUS issues the following basic types of error messages: • FORMSPEC • VPLUS Intrinsics • SNA DHCF • REFSPEC • REFORMAT The following tables provide a map of the classification of messages within each category, the number range for the classification, and the associated page numbers where error information can be found.
-
VPLUS Error Messages FORMSPEC Error Messages FORMSPEC Error Messages Access Method Messages Error Message 086 Access method: file code error. 087 Access method: Attempt to add a duplicate key. 088 Access method: Internal error. Key insertion location error. 089 Access method: Internal error. Block not present. 090 Access method: Attempt to open an old file as new. 091 Access method: Internal error. Key block buffer error, 092 Access method: Internal error. Invalid key block number.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message Cause/Action 102 Form ! is too big to becompiled. Form code record has exceeded 8K bytes. Maximum number of fields is 127. Reduce the number of fields, size of screen, or amount of processing specifications. 103 An END FIELD must have a matching START FIELD. Check your screen design to make sure that each "end field" delimiter has a matching "begin field" delimiter.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message 120 Terminal error initializing old screen. (COM’STATUS !!!!) 121 Terminal error writing old screen. (COM’STATUS !!!!) 122 Terminal error reading screen. (COM’STATUS !!!!) 123 Error writing the screen source. File full? (FSERR!!!!) Cause/Action See error 106. Could not write the screen source record to the form file. First try to correct the problem using the information given in the File System error message.
-
VPLUS Error Messages FORMSPEC Error Messages Field Symbol Table Messages Error Message Cause/Action 301 Internal error: FST ALLOCATE for form ! failed. FST is Field Symbol Table. See error 129. 302 Internal error: Field symbol table for form ! is missing. See error 123. Could not find Field Symbol Table for old form in form file. Press ENTER on screen design to re-create FST. 303 Error writing FST to forms file. File full? Could not write FST record in forms file. See error 123.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message Cause/Action The field number cannot be more than 256. Too many modifications have been made to the screen for this form. The form must be rebuilt from scratch or renumbered in batch.
-
VPLUS Error Messages FORMSPEC Error Messages Menu Processing Utility Messages Error Message Cause/Action 601 Must be B, H, I, U, 1-8, in any combination, or NONE. Enhancement code is incorrect; check and correct. 604 The name cannot have embedded blanks. A field or form name has embedded blank; delete blank or use underline (_). 605 The form name must be unique for this forms file. Form name duplicates another form name in file; make name unique.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message Cause/Action 705 Must be N (no repeat), R (repeat), or A (repeat and append). Correct Repeat Option on FORMS menu. 706 Must be C (clear), A (append), or F (freeze, then append). Correct Next Form option on FORMS menu. 707 Internal error writing top lines to terminal.then append). Field Menu. 708 Internal error writing terminal initialization.(COM’STATUS !!!!) 709 Internal error writing field specs to terminal.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message Cause/Action 723 Selection must be one of the characters listed below. Enter one of the specified characters in the MAIN menu selection box. 724 This selection requires a form name to be supplied. Specify a form name in the appropriate box, or enter a different character in the selection box. 725 Err writing form int’m. rec for form !. File Full? (FSERR !!!) See error 123. Field Symbol Table error.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message Cause/Action 751 This file is not a VPLUS Forms File. You specified an incorrect file name. 752 Error opening the Fast Forms File. (FSERR !!!!) 753 Error reading the forms file. (FSERR !!!!) 754 Error writing to the Fast Forms File. File full? (FSERR !!!!) 755 Error finding the correct record. (FSERR !!!!) 756 Error reading the chained records. (FSERR !!!!) 757 Error opening the old Fast Forms File.
-
VPLUS Error Messages FORMSPEC Error Messages Batch Mode Messages Error Message Cause/Action 769 Invalid batch mode command. FORMSPEC expected a valid batch mode command or parameter. 770 Warning: Forms file modified and not compiled. The forms file must be compiled before it can be used. 771 Could not open command and not compiled. Check file name, security, or if in use elsewhere. 772 Could not open list file. Check file name, security, or if in use elsewhere.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message Cause/Action 789 All commands ignored until next FILE command. Either a command was not recognized or an error occurred with a FILE command. 790 Compile failed.
-
VPLUS Error Messages FORMSPEC Error Messages RELATE Command Messages Error Messages Cause/Action 791 Child cannot have the same name as parent. Same form name was specified as the parent and child form. 792 Form is already child of that parent. The forms are already related. 793 Child form is already related to another parent. A child cannot have more than one parent. 794 Form specified as child cannot have any children. A child form cannot be a parent.
-
VPLUS Error Messages FORMSPEC Error Messages Error Messages 808 Error in VGETBUF. (COM’STATUS !!!!) 809 Error writing source to forms file. File full? (FSERR !!!!) See error 123. 811 Internal error reading form record for form !. (FSERR !!!) See error 123. 812 Internal error reading globals record. (FSERR !!!!) See error 123. 813 Internal error allocating GLOB’SCREEN for form !. 814 Internal error allocating STBL for form !. 815 NEXT is not meaningful until a forms file name is specified.
-
VPLUS Error Messages FORMSPEC Error Messages Error Messages Cause/Action 829 Invalid Multifunction reader definition (COD, CAD, NONE). Enter one of the valid Multifunction reader definitions. 830 Invalid barcode type (UPC, EAN, I25, I39, MAT, ILV). Enter one of the valid Barcode Reader types. 831 Internal error: Writing device intermediate record (FSERR !!!!) 832 Invalid combination of PAUSE INTERVAL and WAIT FOR USER If Split Message Pause is specified, Wait for User must be NO.
-
VPLUS Error Messages FORMSPEC Error Messages Init and Compile Messages Error Message Cause/Action 902 For form !, the next form ! has not been defined. The next form name specified does not exist in the forms file. Change the next form name or create a form with that name. 903 The head form ! has not been defined. The head form specified on the globals menu does not exist in the forms file. Create a form with the head form name or change the head form on the globals menu.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message 923 Internal error: For form !, allocating local buffer for field !. 924 Internal error: For form !, reading source for field !. (FSERR !!) 925 In form !, field ! has an invalid initial value. The initial value specified does not match the field data type. 926 In form !, field name !is a reserved word. Check list of reserved words and change field name. 927 The initial value contains an invalid MDY date value.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message Cause/Action 997 Form !, field ! has a data type error; press NEXT to see error. Data type inconsistent with specification; NEXT displays NEXT to see error. FIELD menu so you can correct data type or specification and press ENTER. 998 Form !, field ! has a syntactic error; press NEXT to see error. NEXT displays FIELD menu so you can correct statement syntax and then press ENTER. 999 Field processing specification syntax error.
-
VPLUS Error Messages FORMSPEC Error Messages Scanner Messages Error Messages Cause/Action 1001 Too many levels of indenting, limit is !!!!. Only 10 levels of nesting are allowed. 1002 Improper indenting, statement groups must be vertically aligned. IF and ELSE parts at same nesting level must be indented vertically aligned the same amount. Maximum levels of nesting for IF is eight levels. 1003 Improper indenting, must be within outer level of indenting.
-
VPLUS Error Messages FORMSPEC Error Messages Parser Messages Error Messages Cause/Action 1094 Invalid name: no field or save field with this name is defined. A valid field name is expected 1095 Internal error. 1096 Semantic error. See error 1098. 1097 Data type error: Data types must be compatible. Data type and value in processing specification do not correspond. 1098 Field processing specification syntax error. Statement is incorrect. Cursor is positioned to the location of the error.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message Cause/Action 1110 CDIGIT operand must be 10 or 11. CDIGIT checks only modulo 10 or 11 check digits. 1120 Too many statements, code for entire form is too big. At compilation, the form information generated does not fit into the maximum record size of 12000 bytes. Reduce the number of fields or processing specifications. 1130 Improper indenting, statement groups must be vertically aligned.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message 1935 Internal error: Invalid operand in MATCH. 1936 Internal error: Invalid operand in CDIGIT. 1937 Internal error: Invalid right operand. 1938 Internal error: Invalid left operand. 1939 Internal error: Invalid source operand. 1940 Internal error: Invalid Dtype in type checking. 1941 Internal error: EXTIN conversion failed. 1942 Internal error: Bad id number. 1943 Internal error: Bad screen order number.
-
VPLUS Error Messages FORMSPEC Error Messages Pattern Compile Messages Error Message Cause/Action 2101 A "(", ")", "[" , or "] is not paired in pattern. MATCH statement contains odd number of parentheses or brackets. 2102 Invalid character found in pattern. A character in the expression is not recognized as a valid character in the pattern. 2104 End of pattern found prematurely. Pattern characters were found after the end of the pattern was found.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message 3109 Internal error: could not flush the globals to the forms file. 3110 Internal error: could not close the formsfile. 3111 List could not open the FORMSPEC formsfile. (FSERR !!!!). 3112 Internal error: List could not close the FORMSPEC formsfile. 3113 List could not find form !in the FORMSPEC formsfile. 3114 List write failed. (FSERR !!!!) 3115 FORMSPECLINESPERPAGE JCW must be between 1 and 150. List failed.
-
VPLUS Error Messages FORMSPEC Error Messages Application-Ready Buffer (ARB) Errors Error Message 3403 Internal error: ARB detail record missing. 3405 This field must not be blank. Enter the required information in the field. 3406 This field accepts only contiguous digits. Remove any spaces between the digits. 3407 Must specify number of decimals here. 3409 Internal error: could not update ARB Detail record. 3412 Internal error: Field Symbol Table record missing.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message 3451 Number specified is not in current ARB range. 3452 ARB is full; no more fields may be added. An ARB may hold up to 256 fields. 3453 Please enter a valid ARB field name. Check the syntax of the name you have entered. 3455 Range is reversed; try ‘leading-field/trailing field’. You have reversed the order of the fields you want to manipulate. The field that appears first on the ARB must appear first in the command.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message 3474 Second field of range is missing; specify ARB field name or number. 3475 Internal error: SearchRec did not locate field in ARB Add. 3476 A range cannot be moved to a destination within itself. 3498 Internal error: VGETBUFFER failed (COM’STATUS !!!!) 3499 Internal error: VPUTBUFFER failed (COM’STATUS !!!!) NOTE 516 Cause/Action In most cases, the corrective action is clearly implied by the message.
-
VPLUS Error Messages FORMSPEC Error Messages ARB Compile Errors Error Message Cause/Action 3500 In ARB !, field ! has no corresponding screen field. Either delete the ARB field, or add a field to the associated screen. 3501 In ARB !, field ! has an incorrect length. Change the ARB field length to match the length of the corresponding screen field. 3502 In ARB !, field ! has an incorrect ARB type. Check the permitted conversion types and correct the ARB data type.
-
VPLUS Error Messages FORMSPEC Error Messages Errors Message 7013 WARNING: if ADD command, form created with no screen. 7014 WARNING: if READD, screen not updated (form renamed?) 7015 Correct syntax is: "FKLABELS formname [˛eystring1...˛eystringn]". 7016 Screenfile contains an invalid character. 7017 Missing datatype parameter 7018 Missing field type parameter. 7019 Missing field enhancement parameter. 7020 SELECTTERM update parameters must be separated by commas.
-
VPLUS Error Messages FORMSPEC Error Messages Errors Message 7034 **** End of compiled forms listing **** 7035 Missing color parameter. 7036 Missing 264x parameter. 7037 Missing 307x parameter. 7038 New function key labels must be preceded by ˙ 7039 End of command file. 7040 Forms file is being converted to new format. 7041 Missing ARB name 7042 Sorry. That command has not been implemented. 7043 Missing ARB field name.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message 8001 Edit contains data inconsistent with language of this forms file. 8002 Edit contains language-dependent data. 8003 Edit contains data not compatible with the language of this forms file. 8004 Invalid initial value for International forms file. 9001 Native language support software not installed. 9002 Language specified is not configured on this system. 9003 Character set specified is not configured on this system.
-
VPLUS Error Messages FORMSPEC Error Messages Error Message 9017 Internal Error: Error updating language ID - try again. 9070 Internal Error: writing terminal selection source record failed 9500 Language of forms file is not configured on this system. 9998 Language ID must be 0 to 999 or -1 for international forms file. 9999 Call to native language support intrinsic failed.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages VPLUS Intrinsic Error Messages VOPENTERM and VCLOSETERM Messages Error Message Cause/Action 001 Internal error: Terminal file initialization failed. failed. FCONTROL or FSETMODE intrinsic 002 Your terminal is not supported by VPLUS. VPLUS works on the HP terminals listed in Appendix G. 003 VPLUS does not run on a series I. VPLUS does not run on an HP Series I computer system. 004 The terminal status request failed.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages Error Message Cause/Action 015 Terminal type incorrectly determined. Possible block mode or data comm problem. Check straps. Note: 2645 multipoint straps should never be touched! 016 Internal error HP2645A multipoint terminal mode not correctly set. See error 015. 017 Comarea too short for run-time HP3075/6 terminals. The Comarea must be 85 words for HP 3075/6 terminals. Set terminals. Comarealen to 85.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages General Messages Error Message Cause/Action 020 Error detected by host language. Check the Comarea item FILERRNUM for the host language error number. 021 Invalid terminal type. See 021 above. 023 Environment control file access failed. VOPENFORMF and VCLOSEFORMF Messages Error Message Cause/Action 040 Internal error: DLSIZE failed; there is not enough DL area space. Stack size or MAXDATA too small.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages Error Message 061 Internal error: Failure to obtain required PASCAL Heap area. 062 Internal error: Failure to return PASCAL Heap area. 063 Failure to close Forms File. (FSERR !) An error occurred while trying to close the forms file. Check that the forms file is open before VCLOSEFORMF is called. 067 Invalid form store size specified.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages VOPENBATCH and VCLOSEBATCH Messages Error Message Cause/Action 070 Forms file was re-complied since last using this batch. You may want to specify a different batch file name since the forms file has been changed since the specified batch file was last used with the forms file. 071 A forms file must be opened before opening a batch file. Call VOPENFORMF before calling VOPENBATCH 072 The file does not appear to be an existing batch file.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages Error Message 092 Access method: Internal error. Invalid key block number. 093 Access method: Internal error. Block not verified. 094 Access method: Record not found. 095 Access method: Not enough space in extension for the directory. 096 Access method: Internal error. Parent block not found. 097 Access method: Internal error. Illegal entry number. 098 Access method: The file is not a KSAMless forms/ref file.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages Error Message Cause/Action 104 Formsfile not compiled for this run-time terminal. The type of terminal is being used has not been selected for use with the forms file. Specify the terminal type in the FORMSPEC Terminal Selection menu, then recompile the forms file.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages VMERGE Messages Following are the messages produced by the VMERGE utility. The cause of each, and the action you may take is also described. Message Cause/Action Action hp32209V.UU.FF VMERGE (c) Hewlett-Packard Co. 1992 ALL RIGHTS RESERVED Header generated at the start of VMERGE processing. No action required. *****Internal processing error (VM1001) An unexpected condition has been detected by VMERGE.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages Message Cause/Action Action ***** Form name table overflow (VM1401) More forms have been found in the MASTER or AUX file than can be accommodated in the form name table. Contact your HP rep. ***** Conflicting data in MASTER forms file (VM1402) Invalid or inconsistent data has been found in the MASTER file. Recreate the file and rerun VMERGE. If the problem persists, contact your HP rep.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages Message Cause/Action Action ***** Number of databases differ (VM1510) The number of databases differ in the MASTER and AUX files. Revise the files to make them compatible and rerun the utility ***** Save fields specifications differ (VM1521) The save field specifications differ in the MASTER and AUX files. Revise the files to make them compatible and rerun the utility.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages Message Cause/Action Action ***** Error reading MASTER file (VM1701) An error occurred in attempting to read the MASTER file. Regenerate the file and rerun VMERGE. ***** Error in MASTER file data (VM1702) An inconsistency was found in the data in the MASTER file. Recreate the file and rerun the utility. If the problem persists contact your HP rep. MASTER file opened (VM1703) Self-explanatory.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages Message Cause/Action Action **** Error writing OUTPUT file (VM1901) Self-explanatory. Correct the problem that has caused the write error and rerun VMERGE. You may need to consult with your system administrator to determine the problem. OUTPUT file opened (VM1903) Self-explanatory. None. ***** OUTPUT file type is not VFAST (VM1904) The file designated as OUTPUT pre-exists but is not of type VFAST.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages VSHOWFORM Messages Error Message Cause/Action 130 Internal Error: Terminal write failed. (FSERR !) FWRITE intrinsic failed. 131 Internal error: Color conversion failed. VREADFIELDS Messages Error Message Cause/Action 150 The supplied read buffer (dbuf) is too small. The data buffer in memory is too small for the data on the form. Check application program DBUF array size and DBUFLEN.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages VPRINTFORM Messages Error Message Cause/Action 190 Can’t open the printfile. (FSERR !) FOPEN intrinsic failed. Refer to file system error to determine the cause. 191 Can’t write to the print file. (FSERR !) FWRITE intrinsic failed. VINITFORM, VFIELDEDITS, and VFINISH Messages Error Message Cause/Action 202 The required field is empty. A required field in current form is blank. 203 Invalid field type.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages Error 222 Message An edit test failed. Cause/Action The default field edit error message had been provided. Check the data you entered in the field against the processing specifications. 321 Attempted a SET into a numeric field that is too short. The destination of a SET statement has fewer characters too short. than the number being moved to it. 323 Internal error: Invalid op code. Code execution problem.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages Error Message Cause/Action 341 Attempted a SET from a field containing an invalid number. A numeric value is expected as the source of a SET statement, but the source is not a valid number. 344 Internal error: Invalid op in long eval. 345 Overflow in an add operation. Value is outside 4-word REAL range. Range of 4-word REAL is from approximately 8.636 times 10^(-78) to 1.158 times 10^77. 346 Overflow in a subtract operation. See error 345.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages VREADBATCH Messages Error Message Cause/Action 400 Can’t read the batch file record. (FSERR !) FREADDIR intrinsic failed. 401 Warning: Can’t browse a batch file with variable length records. Browse mode is illegal for batch records which are not fixed length. VWRITEBATCH Messages Error Message Cause/Action 450 Can’t write the batch record. (FSERR !) FWRITEDIR intrinsic failed.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages Error Message Cause/Action 508 Error reading function key values from forms file (FSERR !!!!) An error occurred while trying to read the function key label definitions from the forms file. 509 Invalid input parameter to function key intrinsics. An invalid value has been passed as the FORM-OR-GLOB or KEY-NUM parameter to VGETKEYLABELS, VSETKEYLABEL, or VSETKEYLABELS intrinsics. 510 A field with the screen order supplied does not exist.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages VGETBUFFER and VPUTBUFFER ARB Messages Error Message Cause/Action 519 ARB flag is set but no ARB record is found. This is an application-specified conversion, but the forms file does not contain an ARB record. Do the following: 1. Initialize ARB conversion flag to 0 if conver sion is not desired. 2. Use FORMSPEC to add the necessary ARB record. 3. Check for possible corruption of the formsfile. 520 ARB conversion type specified is not supported.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages VGETLANG and VSETLANG Messages Error Message Cause/Action 9002 Language specified is not configured on this system. Select another language or check with System Manager to configure the desired language. 9014 Attempted setting a language dependent forms file to another language. VSETLANG can only be used with international forms files. VCHANGEFIELD Messages Error Message Cause/Action 850 Invalid field type specification.
-
VPLUS Error Messages VPLUS Intrinsic Error Messages Error Message 604 INFO intrinsic: Form record read error (FSERR !!!!). 605 FF version is old. Must recompile to use FORMINFO intrinsic. 606 Invalid field specified to FIELDINFO intrinsic. 607 Invalid form # specified to FORMINFO intrinsic. Cause/Action Make sure that the field name is correctly spelled if the field name is the key; make sure that the field name parameter is 16 bytes long, and padded with ASCII blanks.
-
VPLUS Error Messages SNA DHCF Intrinsic Messages SNA DHCF Intrinsic Messages Native Language Support Error Message 8000 This edit statement is not valid for international forms files. 8001 Edit contains data inconsistent with language of this forms file. 8002 Edit contains language dependent data. 8003 Edit contains data not compatible with the language of this forms file. 8004 Invalid initial value for international forms file. 9001 Native Language Support Software not installed.
-
VPLUS Error Messages SNA DHCF Intrinsic Messages Error Message 9012 This edit requires a configured language. 9013 Encountered invalid Asian (2-byte) character. 9014 Attempted setting a language dependent forms file to another language. FORMSPEC language can only be 0 in this version. 9015 NATIVE-3000 is currently the only selection available. FORMSPEC language can only be a 0 in this version. 9016 Invalid date value for international forms file.
-
VPLUS Error Messages REFSPEC Messages REFSPEC Messages Access Method Errors Error Message 086 Access method: file code error. 087 Access method: Attempt to add a duplicate key. 088 Access method: Internal error. Key insertion location error. 089 Access method: Internal error. Block not present. 090 Access method: Attempt to open an old file as new. 091 Access method: Internal error. Key block buffer error. 092 Access method: Internal error. Invalid key block number.
-
VPLUS Error Messages REFSPEC Messages Output Sequence Definition Errors Error Message Cause/Action 101 Field name has more than 15 characters. Limit name of input field to 15 characters. 102 Field name improperly aligned on screen. Enter input field name at tab position 1. 103 Form name has more than 15 characters. Limit name of input form to 15 characters. 104 Form name ! is not ininput forms sequence. A form name on the OUTPUT RECORD menu was not named on corresponding INPUT FORMS menu.
-
VPLUS Error Messages REFSPEC Messages Error Message Cause/Action 127 Output field length is improperly aligned on screen. Enter output field length at tab position 7. 129 Output field starting offset can only have up to 5 digits. Starting column of output field must not exceed 5 digits. 130 Output field starting offset is improperly5 digits. Starting column of output field must not exceed 5 digits. 131 Start record indicator is not in its field. Enter start-of-record marker at tab position 8.
-
VPLUS Error Messages REFSPEC Messages Error Message Cause/Action 145 "Y" or "N" expected in upshift field. On GLOBALS menu, only a Y or N can be entered in response to "Upshift?"; default is N. 146 "Y" or "N" expected in answer to "Convert to EBCDIC?". On GLOBALS menu, only a Y or N can be entered in response to "Convert to EBCDIC?"; default is N. 147 Illegal character. Character in output record menu is neither alphabetic nor numeric. 148 This is not a field.
-
VPLUS Error Messages REFSPEC Messages Validation Errors Error Message Cause/Action 201 Field ! not found in form !. Input field in OUTPUT RECORD menu not found in specified form. 202 Field ! not found in any form in input forms sequence. Input field in OUTPUT RECORD menu not found in any form in the sequence. corresponding INPUT FORMS menu. 203 Reformat identifier ! is not a unique reformat sequence. First form specified on INPUT FORMS menu is not unique to the identifier. reformat file.
-
VPLUS Error Messages REFSPEC Messages Error Message Cause/Action 216 Internal error reading reformat intermediate record for !. Error reading an internally used record from the reformat file. 217 WARNING: Start column goes beyond global output record length. Starting column for output record specified on OUTPUT RECORD menu is greater than the record length on the GLOBALS menu. To avoid truncation, change one of the two specifications. 218 Embedded blank form names not allowed in a sequence.
-
VPLUS Error Messages REFSPEC Messages Field Table Errors Error Message Cause/Action 301 Internal error: OFST ALLOCATE failed. Space allocated for dynamic array is insufficient. 302 Internal error: OFST record missing. Write failed previously. Attempt to read internal record failed because the record did not exist. 303 Internal error: OFST write failed. (FSERR !!!!) Attempt to write an internal record failed. 304 Internal error: OFST does not have any more room.
-
VPLUS Error Messages REFSPEC Messages Error Message Cause/Action 405 Internal error reading input seq from reformat file. (FSERR !!!!) See error 402. 406 Internal error: Input seq table record missing. Prev write failed. See error 302. 407 Internal error writing seq table to refmt file. (FSERR !!!!) 450 Form ! does not exist in the forms file. Form name specified on INPUT FORMS menu is not in forms file. Check name and correct it. 451 Internal error reading glob forms buf from form file.
-
VPLUS Error Messages REFSPEC Messages Menu Processing Errors Error Message Cause/Action 501 Selection field cannot be blank. Enter one of the following codes in the MAIN menu selection box: A, X, G, F, L, or D. 502 Reformat identifier ! not found. A reformat id entered on the MAIN menu is not in the reformat file. Check the INPUT FORMS menu or correct the identifier. 503 Output field name ! not found. An output field name entered on the MAIN menu is not in the reformat file.
-
VPLUS Error Messages REFSPEC Messages Error Message Cause/Action 516 Field name must be blank for this option. A selection was made on the MAIN menu that cannot use an output field name. Clear the output field box.
-
VPLUS Error Messages REFSPEC Messages Menu Processing Utility Errors Errors Message Cause/Action 600 NUMn can have digits only from "O" to "9". A value other than a digit was entered for a NUMn type field; change the data type or the selection. 606 Must be NUMn, DIG, IMPn,MDY, DMY, YMD, or CHAR. Enter one of the listed codes as the data type of this field; n can be a digit 0-9 for NUM, 1-9 for IMP. 608 Justify field must be "L", "R", "C", or " ".
-
VPLUS Error Messages REFSPEC Messages Errors Message Cause/Action 621 Expected "F", "V", or "U" in record format field. Enter one of the listed codes in the Output Record Format box of the GLOBALS menu; default is F (fixed length). 622 Record size must be a numeric value less than 32767. Enter a positive integer less than 32767 in the Record Length box of the GLOBALS menu, or leave the default length of 80 characters. 624 Expected literal, system constant or ASCII equivalent in string.
-
VPLUS Error Messages REFSPEC Messages Menu Init and Processing Errors Error Message 702 Internal error. Intrinsic ASCII failed. 703 Largest legal integer value is 32767. Error in Record Length field of GLOBALS menu. 704 Length of field cannot be negative. Negative value specified as field length on OUTPUT RECORD menu. 705 Internal error initializing OUTPUT RECORD menu. (COMSTATUS !!!!) Internal error in writing the header part of the output record menu.
-
VPLUS Error Messages REFSPEC Messages Error Message 746 Internal error in cursor positioning before read. 747 Internal error writing the current reformat rec for !. (FSERR !!!) 748 Internal error initializing Input Form Menu for reformat id !. 749 Internal error reading MAIN MENU form. (COMSTATUS !!!!) 750 Internal error showing MAIN MENU form. (COMSTATUS !!!!) 751 Internal error getting MAIN MENU form. (COMSTATUS !!!!) 752 Internal error in initializing output record menu.
-
VPLUS Error Messages REFSPEC Messages Menu Controller Errors Error Message Cause/Action 802 The PREV key is not allowed here. There is no previous menu. 803 The function key just hit is not defined for this mode. This key has not meaning on the current menu. 805 Error getting next form !. (COM’STATUS !!!) 806 Internal error in VSHOWFORM. (COM’STATUS !!!!) 807 Internal error in VREADFIELDS. (COM’STATUS !!!!) 808 Internal error in VGETBUF.
-
VPLUS Error Messages REFSPEC Messages Error Message Cause/Action 822 WARNING: Changes in input forms menu may have invalidated this menu. The OUTPUT FIELD menu may be affected by changes to the INPUT FORMS menu. 823 WARNING: Changes in input forms menu may have invalidated this menu. The OUTPUT RECORD menu may be affected by changes to the INPUT FORMS menu. 824 Internal error: Missing record for reformat !. Prev write failed.
-
VPLUS Error Messages REFSPEC Messages Init and Compile Errors Error Message 906 Error writing reformat !. (FSERR !!!) 913 Internal error closing your forms file. (FSERR !!!!) 914 Internal error in storing the field symbol table. (FSERR !!!! ) 917 Internal error in storing OFST. (FSERR !!!!) 918 Error closing reformat file. (FSERR !!!!) 919 Internal error in closing REFSPEC forms file. (FSERR !!!!) 920 Internal error in closing terminal file.
-
VPLUS Error Messages REFSPEC Messages Error Message 1005 Internal error reading field intermediate code rec. (FSERR !!!!) 1006 REFSPEC version has been changed. Reformat file invalid. The specified reformat file was produced on an earlier version of REFSPEC. 1007 Reformat file is empty. There is nothing to compile. Enter A to add a reformat before entering X to compile. 1008 Error in output record menu in reformat !. Go to the OUTPUT RECORD menu for the specified reformat, and make correction.
-
VPLUS Error Messages Reformat Messages Reformat Messages Reformat Messages Error Message Cause/Action 2 Error opening reformat file. (FSERR !!!!) Check file system error number. 4 Batch file could not be opened. (FSERR !!!!) Check file system error number. 5 No reformatting was done. No sequence of forms in batch matched with any Reformat sequence. 6 Batch file: ! Not an error. Listing message. 8 Error closing batch file. (FSERR !!!!) Check file system error number.
-
VPLUS Error Messages Reformat Messages Error Message Cause/Action 23 Internal error getting information from batch file. (FSERR !!!!) FGETINFO failed. 24 File specified was not a reformat file. Check reformat file name in :FILE command.
-
VPLUS Error Messages Reformat Messages Allocation Messages Error Message 30 Internal error: Batch data space too small. Allocation failed. 31 Internal error allocating batch information buffer. 32 Internal error allocating batch data buffer. 33 Internal error allocating batch temporary buffer. 34 Internal error allocating reformat code buffer. 35 Internal error allocating output buffer. 36 Internal error allocating temporary output buffer. 37 Internal error allocating data buffer.
-
VPLUS Error Messages Reformat Messages Access Method Messages Error Message 086 Access method: file code error. 087 Access method: Attempt to add a duplicate key. 088 Access method: Internal error. Key insertion location error. 089 Access method: Internal error. Block not present. 090 Access method: Attempt to open an old file as new. 091 Access method: Internal error. Key block buffer error. 092 Access method: Internal error. Invalid key block number. 093 Access method: Internal error.
-
VPLUS Error Messages Reformat Messages Error Message Cause/Action 102 Field separator causes output record overflow. Data truncated. See error 101. See globals menu. 103 Literal causes output record overflow. Data truncated. A literal constant in output record makes record longer than output record length defined for file in GLOBALS menu. 104 Internal error: Bad code for reformat sequence. 105 Output length greater than largest possible output record.
-
VPLUS Error Messages Reformat Messages Statistics Messages Error Message Cause/Action 200 Reformatting completed successfully with no errors. Hurrah! 201 !!!! reformats attempted. Message reports how many times reformat identifiers were matched with records in the reformat file. 202 !!! records written to output file. This message tells you the total number of reformatted records written by REFORMAT. Message is always issued. 203 !!! batch records processed.
-
VPLUS Error Messages Reformat Messages Error Message Cause/Action 308 Invalid data in date input field. Output field expects a date, but batch field does not contain a date. 309 No data movement. Truncation of significant data would occur. The numeric data is not written to the output field because it would be truncated. 315 Non-numeric characters cannot be converted to zone decimals. Output field defined as SIGN = Z, but batch field does not contain zone decimals. numeric data.
-
VPLUS Error Messages Reformat Messages Error Message Cause/Action 328 Internal error: More than 9 decimal places expected. See error 321. 329 An all blank field is not a legal implied value. A batch field to be converted to an IMPn type output field must contain values other than blanks. 330 Commas in implied data field are not correctly positioned. In an IMPn type field, commas should be positioned counting back from the implied decimal point.
-
VPLUS Error Messages Reformat Messages Message Info Error Message 400 Reformat identifier: ! 401 Reformat field name: ! 402 Batch record form name: ! 403 Batch record #: !!! 404 Output record #: !!! 405 Output record col #: !!!! Cause/Action Header Messaages Error Message Cause/Action 500 ******************************* ********************************** 501 * 502 * REFORMAT HP32209! 503 * ! 504 PAGE !!!! 505 ! * * * 506 507 REFORMAT/3000 HP32209! Testlist Errors Error
-
VPLUS Error Messages Reformat Messages Native Mode Access Error Messages Error Message 996 Forms file must be adjusted with FORMSPEC before it can be used. 997 Forms file is corrupt. 998 Negative argument passed to VPLUS intrinsics See Appendix J. 999 Attempt to access Compatibility Mode VPLUS services failed. See Appendix J.
-
USASCII Character Set in Collating Sequence ASCII Character Set C USASCII Character Set in Collating Sequence ASCII Character Set Table C-1. ASCII Character Set Hex. Dec.
-
USASCII Character Set in Collating Sequence ASCII Character Set Table C-1. ASCII Character Set Hex. Dec.
-
USASCII Character Set in Collating Sequence ASCII Character Set Table C-1. ASCII Character Set Hex. Dec.
-
USASCII Character Set in Collating Sequence ASCII Character Set Table C-1. ASCII Character Set Hex. Dec.
-
USASCII Character Set in Collating Sequence ASCII Character Set Table C-1. ASCII Character Set Hex. Dec.
-
USASCII Character Set in Collating Sequence ASCII Character Set 578 Appendix C
-
CHECK DIGIT CALCULATION D CHECK DIGIT CALCULATION Check digits are digits added to the end of a value that contains only numbers (0-9) or letters of the alphabet (A-Z). A FORMSPEC option can be selected that causes a modulus check to be made on a value entered at the terminal. Whenever a value is entered for which check-digit verification has been specified, a modulus calculation is performed.
-
CHECK DIGIT CALCULATION MODULUS 10 MODULUS 10 Modulus 10 calculations detect single transpositions and incorrect keying of a single digit. The calculation is performed as follows: • The units position and every alternate position of the basic number is multiplied by 2. • The digits resulting from the multiplication are added to those that were not multiplied. • The total is subtracted from the next higher number ending with zero. The result is the check digit.
-
CHECK DIGIT CALCULATION MODULUS 11 MODULUS 11 Modulus 11 detects single digit errors, single transpositions, and double transpositions. Unlike other check digit systems, it is based on a weighted checking factor for each digit in the basic number. The modulus 11 check digit is obtained as follows: • Each digit position of the basic number is assigned a weighted checking factor .
-
CHECK DIGIT CALCULATION ALPHABETIC CHECK DIGITS ALPHABETIC CHECK DIGITS Letters of the alphabet are treated like numbers in either modulus 10 or modulus 11 check digit calculations. This is done by assigning a digit to each letter of the alphabet as follows: A B C D E F G H I J K L M N 0 P Q R S T U V W X Y Z ( =space) 1 2 3 4 5 6 7 8 9 1 2 3 4 5 6 7 8 9 2 3 4 5 6 7 8 9 0 A value to be checked may be preceded by a plus or minus sign; however, the sign is ignored in the check digit calculations.
-
Application Hints E Application Hints This appendix provides hints and guidelines on the following topics • Designing your Forms File • Rules for the DL Area • Coding the Touch Feature Appendix E 583
-
Application Hints Designing Your Forms File Designing Your Forms File The following hints may help you design your forms file with FORMSPEC: 1. If the status/window line is the last line on the screen, it should be no longer than 79 characters. This is because using the 80th character on the bottom line of the screen causes the screen to roll up one line temporarily. If this roll-up is not a problem, then the last line can use 80 characters. 2.
-
Application Hints Designing Your Forms File BT. The following specifications are entered in the F1 Field Menu to ensure that only the correct values are summed: INIT SET OLDF1 TO 0 \executed only in collect mode FIELD SET BT TO BT + F1 - OLDF1 \executed in browse or collect mode SET OLDF1 6. If you want to include a logical AND function in your processing specifications, use nested IF statements.
-
Application Hints Designing Your Forms File IF EO MINLEN 1 THEN ELSE EO not marked; apply edits 8. The contributed utility program RESTORE will not correctly copy records larger than 2000 bytes. If you wish to copy a KSAM forms file or reformat file from a store tape to a disc file, use the MPE :RESTORE command and the FCOPY subsystem. 9. There are three file equations for which VPLUS checks during execution.
-
Application Hints Designing Your Forms File For example, the MPE command :SETJCW FORMSPECLINESPERPAGE=45 sets the maximum number of lines per page to 45. This JCW is useful when more white space is desired at the bottom of the page, or when special paper is used. FORMSPECLINESPERPAGE must be in the range 1 to 150. Any value outside this range will cause a LIST command to fail, and will cause batch mode FORMSPEC to halt with the error message.
-
Application Hints Rules for the DL Area Rules for the DL Area VPLUS makes use of the DL area for buffers and internal tables. Therefore, if the DL area is put to any other use during the execution of a VPLUS application, such use must not conflict with that of VPLUS. To insure against conflict, observe the following rules: 1.
-
Application Hints Coding the Touch Feature Coding the Touch Feature In order to use the touch feature effectively, a method is needed to provide feedback to the user when a field is touched. Changing the field enhancement is one of the best methods to indicate that a field has been touched. The enhancement of a field can be changed by using the VCHANGEFIELD intrinsic, or family forms. If neither of these methods is appropriate and the error count is not important, VSETERROR can be used instead.
-
Application Hints Coding the Touch Feature 590 Appendix E
-
STATE/POSTAL CODES F STATE/POSTAL CODES The special system constant $STATE consists of a table of all the state codes for the 50 states of the United States, plus U. S territories, armed services and other valid postal codes. When an entered postal code is matched against the table, the entered code can be in any combination of upper or lowercase letter. For instance the code for California is CA; any of the following codes can be successfully matched against the California code: CA, ca, Ca, or even cA.
-
STATE/POSTAL CODES Kansas KS Utah UT Kentucky KY Vermont VT Louisiana LA Virginia VA Maine ME Virgin Islands VI Marshall Islands MH Washington WA Maryland MD West Virginia WV Massachusetts MA Wisconsin WI Michigan MI Wyoming WY Minnesota MN 592 Appendix F
-
TERMINAL INFORMATION G TERMINAL INFORMATION This appendix contains information about terminals that affects the operation of VPLUS. An overview of the supported terminals and their main features is followed by information on terminals, grouped according to terminal family and model within the family.
-
TERMINAL INFORMATION SUPPORTED TERMINALS AND FEATURES SUPPORTED TERMINALS AND FEATURES VPLUS can be used with the following terminals: • HP 150* • HP 2392A • HP 2622A • HP 2640B • HP 3075A • HP 2382A • HP 2393A • HP 2623A • HP 2641A • HP 3076A • HP 2394A • HP 2624A • HP 2642A • HP 3081A • HP 2397A • HP 2624B • HP 2644A • HP 2625A • HP 2645A • HP 2626A • HP 2647F** • HP 2627A • HP 2648A • HP 2628A * HP 150 is obsolete and not supported for this release.
-
TERMINAL INFORMATION SUPPORTED TERMINALS AND FEATURES Extended Local Edits This feature provides for the editing of information by the terminal as it is typed into the form. You specify the editing to be done by using the command LOCALEDITS in the field processing specification section. The HP 2624B and HP 2394A terminals supports this feature. Relabeling Function Keys This feature allows you to specify during forms creation or modification time function key labels that will be used during data entry.
-
TERMINAL INFORMATION SUPPORTED TERMINALS AND FEATURES Table G-1. Terminals Supported by VPLUS ID * MODEL 13 2624B 14 2382A 15 3075A 15 3081A 16 3076A 17 + 3077A 18 * 2621B GRAPH COLOR TOUCH LFS MDT LOCAL EDITS SEC ENH X.
-
TERMINAL INFORMATION SUPPORTED TERMINALS AND FEATURES This feature is supported on the HP 2394A, HP 2624B and HP 2626A terminals, and is fully described in Section 6. X.25 Capability This feature allows X.25 block mode to be used via a PAD interface with the following terminals: HP 150 (obsolete and not supported) HP 2392A HP 2622A* HP 2625A HP 2393A HP 2623A* HP 2627A HP 2394A HP 2624B* HP 2628A HP 2397A * Check ROMS for auto keyboard lock.
-
TERMINAL INFORMATION SUPPORTED TERMINALS AND FEATURES VGETSCPDATA Returns information about the cursor location by field number and row and column number on a VPlus screen. These intrinsics enable application programs to determine where the cursor was left on a VPlus screen after a read operation. The information returned to the application varies with the intrinsic used.
-
TERMINAL INFORMATION THE HP 264X TERMINALS THE HP 264X TERMINALS The HP 264X terminal family is the terminal default — you do not need to access FORMSPEC's Terminal/Language Selection Menu unless you need to change the default. However, if you want function key labeling for HP 264X terminals, you must access the Terminal/Language Selection Menu and specify Y in the HP 264X Family field.
-
TERMINAL INFORMATION THE HP 264X TERMINALS HP 2644A Terminal This terminal must be placed in block mode. When the terminal is opened by FORMSPEC, ENTRY, REFSPEC, or an application, a message is displayed asking you to press the block mode key. Also, when the terminal is closed, a message reminds you to unlatch the block mode key.
-
TERMINAL INFORMATION THE HP 262X TERMINALS THE HP 262X TERMINALS VPLUS runs on the HP 262X family without any special action by you (without specifying the HP262X, HP239X Families on FORMSPEC's Terminal/Language Selection Menu) except in the special cases noted in the following paragraphs. To use X.
-
TERMINAL INFORMATION THE HP 262X TERMINALS HP 2626A Terminal To utilize the security display enhancement feature of the HP 2626A, you must specify the HP262X, HP239X Families on FORMSPEC's Terminal/Language Selection Menu. The HP 2626A terminal can store as many as four forms locally depending on the size of the forms. VPLUS utilizes the workspace/window feature of this terminal and configures terminal memory into from one to four workspaces.
-
TERMINAL INFORMATION THE HP 239X AND HP 150 TERMINALS THE HP 239X AND HP 150 TERMINALS VPLUS runs on the HP 2 39X and the HP 150 terminals without any special action by you (without specifying the HP262X, HP239X Families on FORMSPEC's Terminal/Language Selection Menu) except in the special cases noted in the following paragraphs. To use X.
-
TERMINAL INFORMATION THE DATA CAPTURE DEVICES THE DATA CAPTURE DEVICES To use the HP 3075A, HP 3076A or HP 3081A devices with VPLUS, you must specify the HP307X Family on FORMSPEC's Terminal/Language Selection Menu. To take advantage of the HP 3081A features, you must specify an eight (8) in the selection box for the HP307X Family on the Terminal/Language Selection Menu. VPLUS only opens or closes the HP 3077A device; no other functions are available.
-
TERMINAL INFORMATION TERMINAL COMMUNICATION AREA TERMINAL COMMUNICATION AREA Positions 49 through 58 (relative to 1) of the VPLUS communication area (comarea) are used for terminal-related information, which includes the terminal file number, terminal type, terminal allocation and error logging, and terminal options. It is not necessary for you to access this area as VPLUS manages it automatically.
-
TERMINAL INFORMATION TERMINAL COMMUNICATION AREA configuration of these bits. When VREADFIELDS is terminated by a function key, VPLUS does not transmit any data entered on the screen to the user buffer. If the programmer wishes for data to be transmitted to the data buffer when a function key is pressed, the AUTOREAD feature should be enabled.
-
TERMINAL INFORMATION TERMINAL BUFFER CONFIGURATION TERMINAL BUFFER CONFIGURATION When using FORMSPEC, ENTRY, REFSPEC, or the intrinsics VREADFIELDS or VSHOWFORM, there must be sufficient terminal buffers available for all concurrently executing terminal I/O operations. The number of terminal buffers must be at least 150 and it is strongly recommended that the number of terminal buffers be set to the maximum allowed on your system, shared by all processes.
-
TERMINAL INFORMATION RECOVERING FROM UNEXPECTED PROGRAM INTERRUPTION RECOVERING FROM UNEXPECTED PROGRAM INTERRUPTION In case of unexpected interruption due to hitting BREAK or a terminal power failure, control returns to MPE. To recover from such a situation, you take the following steps: 1. Perform a hard reset.
-
TERMINAL INFORMATION USER ENVIRONMENT CONTROL FILE USER ENVIRONMENT CONTROL FILE The user environment control file is called VENVCNTL.PUB.SYS, and is designed to let the programmer assert limited control over terminal activities. It is opened and read on the VOPENTERM call, and it controls these two items in the user environment. 1. Abbreviating a terminal query. When VOPENTERM is called, it usually goes through a complicated process to identify the terminal type.
-
TERMINAL INFORMATION ADVANCED TERMINAL I/O PROCEDURES ADVANCED TERMINAL I/O PROCEDURES In general, the VPLUS terminal input/output procedures such as VOPENTERM, VCLOSETERM, VREADFIELDS and VSHOWFORM are sufficient for most applications that communicate with a user via a terminal interface. In building complex user interfaces, however, application designers have a limited number of tools for implementation.
-
TERMINAL INFORMATION VTURNON/VTURNOFF VTURNON/VTURNOFF VOPENTERM configures the driver and the terminal for block mode access. VCLOSETERM configures the terminal and driver for character mode access. These procedures initialize the terminal in many ways, including clearing the screen image. VTURNON and VTURNOFF reconfigure the terminal and driver but leave the terminal screen image intact. VTURNOFF allows the application to switch momentarily to character mode from block mode without disturbing the screen.
-
TERMINAL INFORMATION VTURNON/VTURNOFF VTURNOFF reconfigures the terminal and driver for character mode operations without disturbing the screen image on the terminal. The following operations normally performed in VCLOSETERM are not performed in VTURNOFF: • Clear local form storage • Enable the USER/SYSTEM keys • Disable touch reporting, delete touch fields • Clear screen • Unlock keyboard • Close terminal file VTURNOFF NOTE VTURNOFF does not close the terminal file.
-
TERMINAL INFORMATION VTURNON/VTURNOFF cstatus Set to zero. language Set too code that identifies the programming language of the calling program. comarealen Set to total number of 2-byte words in comarea. VTURNON may set the following comarea fields. cstatus Set to nonzero value if call is unsuccessful. fileerrnum Set to file error code if there is an MPE file error. filen Set to MPE file number of terminal. identifier Set to appropriate VPLUS terminal ID.
-
TERMINAL INFORMATION VTURNON/VTURNOFF 614 Appendix G
-
Version Control H Version Control This appendix provides information on: • KSAM File Control and Conversion to MPE Files • Adjust Menu • The HP32209 intrinsic • The HP32209B utility Appendix H 615
-
Version Control KSAM File Management KSAM File Management Since the release of version B.03.23 of VPLUS, VPLUS accepts only MPE files with the file code of VFORM. VPLUS has created only MPE files since VPLUS version A.01.01. Prior to A.01.01, VPLUS created KSAM files. Any KSAM file created by VPLUS before version A.01.01 will continue to function when accessed through FORMSPEC, REFSPEC, ENTRY or your applications without any actions on your part.
-
Version Control KSAM File Management :FCOPY FROM=ORDFORM;TO=(ORDFORM2,ORDKEY2) This will copy only the active records in the KSAM file named ORDFORM to the new KSAM file named ORDFORM2 whose key file in ORDKEY2, also a new file. The utility program CONVERT.PUB.SYS will create an MPE file from the KSAM file created above: :RUN CONVERT.PUB.SYS PLEASE ENTER NAME OF THE OLD FORMS FILE. ORDFORM PLEASE ENTER THE NEW FORMS FILE NAME.
-
Version Control Adjust Menu Adjust Menu The Adjust Menu is automatically displayed from the Forms File Menu the first time a forms file created before VPLUS version B.03.03 is accessed from FORMSPEC version B.03.03 or beyond. You are given a choice of exiting FORMSPEC by pressing f8, or continuing with the adjustment process by entering CONTINUE into the only field on the Adjust Menu. It is recommend that you create a backup copy of the forms file before the adjustment.
-
Version Control The HP32209B Utility The HP32209B Utility The HP32209B utility provides you with a simple way to confirm the version of the VPLUS software that you are currently running on the system. HP32209B resides in the PUB.SYS group and account. You can use it by typing the MPE command :RUN HP32209B.PUB.SYS The screen will display the product name and version as well as the version number of each segment of the software.
-
Version Control The HP32209B Utility 620 Appendix H
-
BIT MAP CONVERSION Syntax I BIT MAP CONVERSION A procedure called BITMAPCNV is provided to help decode and set bits in programming languages which do not have bit operations. It is particularly helpful in COBOL with the bit map returned by VGETFIELDINFO. Syntax BITMAPCNV {bitmap,bytemap,numbytes,function,cnverr} Parameters bitmap Source bit array containing bits to be converted to a byte array, or destination bit array for conversion from a byte array. bytemap Destination or source byte array.
-
BIT MAP CONVERSION Discussion Discussion This procedure can be used to set bits in the comarea. It can also be used to decode the error bit map returned by VGETFORMINFO. The BITMAPCNV procedure decodes a bit map to a byte array if the function parameter contains a value of one. Each byte in the byte array represents the corresponding bit in the bit map. If a bit in the bit map is on (value of one), the corresponding byte will contain the character of one (1).
-
HP PRECISION ARCHITECTURE J HP PRECISION ARCHITECTURE This appendix offers some guidelines for the migration of programs developed on MPE/V to MPE/XL systems, and a short list of peripherals and languages supported on MPE/XL systems. It also provides information on those aspects of VPLUS that pertain exclusively to MPE/XL running on the HP Precision Architecture (HPPA) systems.
-
HP PRECISION ARCHITECTURE MIGRATION ISSUES MIGRATION ISSUES Programs that were originally developed on MPE/V must be rewritten to run in native mode on the MPE/XL. For details, refer to the following reference manuals: • Migration Process Guide describes how to migrate existing applications to MPE/XL. • Programmers' Skills Migration Guide explains new program development on MPE/XL and serves as a reference to the operating system.
-
HP PRECISION ARCHITECTURE MIGRATION ISSUES switch stubs, which require the correct parameter types. The wrong parameter causes a run-time error because the VPLUS native mode access layer does not have the capacity to edit the data passed through it. If your application fails with a VPLUS error 998 or 999, or a memory fault, you can take the following steps: 1. Activate the VPLUS trace facility and examine the trace, especially the entering and leaving messages from the VPLUS native mode stub software. 2.
-
HP PRECISION ARCHITECTURE HPPA INTRINSICS HPPA INTRINSICS Introduction On the MPE/V and previous systems, Hewlett Packard represented real or floating point numbers in a format unique to each machine. However, on the MPE/XL systems, these numbers are represented in a format that conforms with an IEEE standard. This means that programs running in native mode on MPE/XL systems will deal with numbers stored in the IEEE format.
-
HP PRECISION ARCHITECTURE HPPA INTRINSICS CHAR type can be converted. NOTE The field number is a unique number assigned to each field by FORMSPEC and is completely independent of the field's position in the data buffer or the form. It only changes if the batch command, RENUMBER, is used. You can alter the length, position or other characteristics of a field without affecting the field number. The field number provides a way to locate fields regardless of their position.
-
HP PRECISION ARCHITECTURE HPPA INTRINSICS their position. The numeric value, stored in the buffer in character coded form, is converted to IEEE floating point long format and then copied to the variable in the application. If errors occur during conversion, cstatus is set to the appropriate error code. If the requested field's error code is set, its value is moved to the variable but cstatus is set to an error code.
-
HP PRECISION ARCHITECTURE HPPA INTRINSICS NOTE The field number is a unique number assigned to each field by FORMSPEC and is completely independent of the field's position in the data buffer or the form. It only changes if the batch command, RENUMBER, is used. You can alter the length, position or other characteristics of a field without affecting the field number. The field number provides a way to locate fields regardless of their position.
-
HP PRECISION ARCHITECTURE HPPA INTRINSICS NOTE The field number is a unique number assigned to each field by FORMSPEC and is completely independent of the field's position in the data buffer or the form. It only changes if the batch command, , is used. You can alter the length, position or other characteristics of a field without affecting the field number. The field number provides a way to locate fields regardless of their position.
-
HP PRECISION ARCHITECTURE HPPA INTRINSICS 19 20 21 22 ------- B’06’08’S19’00 B’06’08’S20’00 B’06’08’S21’00 B’06’08’S22’00 -------------- VPLUS NATIVE MODE INTRINSICS VERSION: OVERLAY VERSION: HP32209B.06.08 B.06.08.00 FOR THIS USER: VPLUS NATIVE MODE IS ENABLED; VPLUS SWITCH TO COMPATIBILITY MODE IS DISABLED; WILL DEFAULT COMPATIBILITY MODE SL SEARCH TO SYSTEM SL DHCF A4004000 VPLUS/Windows VERSION: HP36393A.00.06 VPLUS/Windows Native Mode VERSION: OVERLAY VERSION: Appendix J HP36393A.00.06 A.00.
-
HP PRECISION ARCHITECTURE HPPA INTRINSICS 632 Appendix J
-
SNA DHCF with VPLUS Applications K SNA DHCF with VPLUS Applications This appendix provides advisory information about running VPLUS applications from IBM 3270 display stations using the Systems Network Architecture Distributed Host Command Facility (SNA DHCF). Note that the IBM 3270 Display System features several display station models. Consequently, this appendix generically refers to this family of display stations as IBM 3270.
-
SNA DHCF with VPLUS Applications SNA DHCF Overview SNA DHCF Overview SNA DHCF enables IBM System 370-compatible mainframes and series 900 HP 3000 systems to communicate interactively. Users of IBM 3270 display stations with access to the IBM Host Command Facility (HCF) can access an HP 3000 in an SNA network and initiate a session on the MPE XL operating system.
-
SNA DHCF with VPLUS Applications IBM 3270 Differences and Limitations IBM 3270 Differences and Limitations When using VPLUS to design or modify applications for IBM 3270 users, it is important to understand the limitations that restrict forms design for IBM 3270 display stations. The information in the following sections explain how an IBM 3270 differs from an HP 3000 terminal and the impact of these differences when running VPLUS applications using SNA DHCF.
-
SNA DHCF with VPLUS Applications IBM 3270 Differences and Limitations Table K-1. Comparison of Major Keys HP 3000 Key Equivalent IBM 3270 Key and Explanation ROLL UP No equivalent key exists. USER KEYS No equivalent key exists. In addition to the keys listed above, IBM 3270 function keys differ from HP 3000 function keys. The IBM keyboard has 12 or 24 function keys; the first 8 function keys map to HP keyboards. Table K-2 shows the mapping of HP function keys to IBM 3270 function keys. Table K-2.
-
SNA DHCF with VPLUS Applications IBM 3270 Differences and Limitations • Character translation Screen Attributes IBM 3270 display stations have the following screen attributes and limitations: Display Area Depending on the IBM 3270 display station model, the display area is either 24, 32, or 43 lines long. The maximum length for a VPLUS form is 24 lines. Consequently, if you display a VPLUS form on an IBM 3270 that has 32 or 43 lines, the lines following line 24 will be blank.
-
SNA DHCF with VPLUS Applications IBM 3270 Differences and Limitations terminals • Local field edits that occur in the terminal firmware, such as edits for numeric fields Screen Enhancements Several HP terminal display enhancements are unavailable on the IBM 3270. You do not have to alter any enhancements specified in an existing forms file for IBM 3270 usage, however. Table K-3 summarizes the mapping of HP display enhancements to IBM 3270 display stations.
-
SNA DHCF with VPLUS Applications IBM 3270 Differences and Limitations Fields You should not design a form that has contiguous fields, because the IBM 3270 display station requires an attribute byte preceding each field or text area. The attribute byte uses a physical screen location and appears as a blank space on the screen. The attribute byte indicates whether the field can be or has been changed.
-
SNA DHCF with VPLUS Applications Using FORMSPEC With DHCF Using FORMSPEC With DHCF You can compile a forms file for an IBM 3270 and any HP terminal that supports VPLUS on MPE/V or MPE/XL by selecting the desired terminals from the Terminal/Language Selection Menu and ensuring that the forms file adheres to IBM 3270 requirements. You must compile a forms file for at least one HP terminal as well as an IBM 3270.
-
SNA DHCF with VPLUS Applications Using FORMSPEC With DHCF at the error location as shown below. In this example, the error is obvious. The field tag D must be moved one column to the right to line up with the other characters. Moving this field allows space for the attribute byte between the colon and the beginning of the field.
-
SNA DHCF with VPLUS Applications Using VPLUS Intrinsics With DHCF Using VPLUS Intrinsics With DHCF From the group of all available VPLUS intrinsics, SNA DHCF does not support two of the intrinsics when they are run on IBM 3270 display stations. Six of the intrinsics can be used, but are altered because of IBM 3270-related differences. The remaining intrinsics can be used in the same manner as for an application to be run on HP terminals.
-
SNA DHCF with VPLUS Applications Using VPLUS Intrinsics With DHCF partial form, because the terminal does not support scrolling and SNA DHCF does not simulate it. Instead, the commands roll up an entire form at a time. • Brackets are not visible around fields. • The function key area is simulated only in VPLUS mode.
-
SNA DHCF with VPLUS Applications SNA DHCF and VPLUS Utilities SNA DHCF and VPLUS Utilities Besides FORMSPEC, SNA DHCF affects certain other applications of the VPLUS-based forms management system as explained in the following sections. ENTRY ENTRY can run on an IBM 3270 if you have compiled the forms file for the IBM 3270. Initial prompts are in TTY-mode and the remaining prompts use standard VPLUS.
-
SNA DHCF with VPLUS Applications SNA DHCF and VPLUS Utilities The following example shows the MPE response when you run utility HP32209S if SNA DHCF/XL is installed on the system. :RUN HP32209S.PUB.SYS VPLUS INTRINSICS VERSION: ------SEGMENT ------01 02 03 04 05 06 07 08 09 10 11 12 13 14 ----- HP32209B.05.
-
SNA DHCF with VPLUS Applications SNA DHCF and VPLUS Utilities 646 Appendix K
-
L A Programmer’s Guide to VPLUS VPLUS is an HP tool used by programmers to design screens and implement an on-line application to collect and display information. With VPLUS, you are able to design screens which prompt the user for input in familiar business terms. VPLUS intrinsics are available to help you develop a customized application. This note is intended for programmers who want to understand the purpose of each intrinsic and the sequence of calls.
-
A Programmer’s Guide to VPLUS VPLUS Intrinsic Calls VPLUS Intrinsic Calls ENTRY.PUB.SYS is an example of an application which uses VPLUS intrinsic calls. This program accepts data from a user and writes the information to an MPE file. The MPE file contains information in the user label for use by ENTRY.PUB.SYS. Since ENTRY.PUB.
-
A Programmer’s Guide to VPLUS VPLUS Intrinsic Calls based on the values of these fields. Other words in the comarea array that need to be set prior to VOPENFORMF’s call are: • LANGUAGE which contains the language code of the calling program • COMAREALEN which contains the length in words of the comarea array. In addition, for BASIC/3000 programs, USRBUFLEN should specify the number of words needed for the comarea extension on the stack.
-
A Programmer’s Guide to VPLUS VPLUS Intrinsic Calls 2. Issue a file equation as follows: :FILE {termfilename};DEV=xx {termfilename} is the name used in your call to VOPENTERM; ‘xx’ is the LDEV of the terminal to which you are redirecting the screens Another method that can be used in your application is to redirect the display of the error message from the program to another device.
-
A Programmer’s Guide to VPLUS VPLUS Intrinsic Calls the formsfile. REPEATAP FREEZAPP is the repeat append option and will take on a numeric value from 0 - 2. These values are defined as follows: 0 Do not repeat the current form 1 1 Current form is to be repeated 2 Current form is to be repeated and appended is the freeze append option. This will also take on a numeric value from 0-2.
-
A Programmer’s Guide to VPLUS VPLUS Intrinsic Calls [COBOL programmers must add 2 to SHOWCONTROL] VSHOWFORM (COMAREA) SHOWCONTROL (14:1)=0 [COBOL programmers must subtract 2 from SHOWCONTROL] Lastly, VGETNEXTFORM may be called with $RETURN. Before performing VGETNEXTFORM, REPEATAPP must be 0 as in all the above cases. VPLUS keeps track of the forms most recently used by your program. $RETURN returns the last form called.
-
A Programmer’s Guide to VPLUS VPLUS Intrinsic Calls COMAREA words have been set from preceding VPLUS intrinsic calls. If CSTATUS word of the user’s COMAREA is not zero, the call to VPUTBUFFER does not execute. The buffer is the name of the program’s form buffer whose contents are to be put to the form. The third parameter is the length of the buffer in bytes. VSHOWFORM Purpose: to display screen definition, data, window function keys, enhancements or terminal screen.
-
A Programmer’s Guide to VPLUS VPLUS Intrinsic Calls For terminals that have local form storage, the current form may optionally be loaded into local form storage if it is not already present. Bit 8=0 Do not enable A/M/U (default). Bit 8=1 Enables A/M/U. If bit 8 is set to 1, users may access the A/M/U. Currently on VPLUS version B.04.20, a VENVCNTL.PUB.SYS file can also control this option; the format of this file is discussed in the Communicator, Volume 2, Issue 13 (UB-DELTA-1).
-
A Programmer’s Guide to VPLUS VPLUS Intrinsic Calls example, if an order processing clerk is entering order information on a screen, then presses a function key labeled “MODIFY”, the program needs to read the data on the screen. Without the AUTOREAD option set, the program would not read the screen. The program needs to interrogate the LASTKEY word of the COMAREA for an i value. If a non-zero value is found, it needs to proceed with enabling AUTOREAD.
-
A Programmer’s Guide to VPLUS VPLUS Intrinsic Calls and the numbers are right justified. This section on “Editing” will cover the three phases of editing: VFIELDEDITS, optional programmatic edits, and VFINISHFORM. VFIELDEDITS Purpose: to verify the data entered. This intrinsic is called to verify the data entered. If the field is defined as OPTIONAL and is left blank, no further processing is performed.
-
A Programmer’s Guide to VPLUS VPLUS Intrinsic Calls programmatic edits detect invalid data, the field may be highlighted and set in error. The pseudocode for VSETERROR looks like: VSETERROR (COMAREA, FIELDNUM, MESSAGE, MSGLEN) VSETERROR sets the field in error if it is not already in error and increments the NUMERRS word of the user’s COMAREA by one. After the call to VSETERROR, NUMERRS reflects the number of fields detected in error on the form.
-
A Programmer’s Guide to VPLUS VPLUS Intrinsic Calls Returning Data to the Program After the data is verified by VFIELDEDITS, optional programmatic edits, and VFINISHFORM, it is returned to the program’s form buffer with a call to VGETBUFFER. There are other intrinsics to return from VPLUS’s data buffer to the program buffer such as VGETtype and VGETFIELD. These two intrinsics can be used to retrieve one field’s worth of data to a program buffer. Refer to the VPLUS/V Reference Manual on their use.
-
A Programmer’s Guide to VPLUS VPLUS Intrinsic Calls VCLOSETERM Purpose: to close the terminal file and reset the terminal out of block mode. This takes the terminal out of block mode and resets the straps. VCLOSETERM only partially restores the terminal’s configuration. One of the things that it does not do is to restore user function key labels. If a VPLUS application terminates abnormally, VCLOSETERM is not done. Therefore, the terminal is not taken out of block mode and echo is not turned back on.
-
A Programmer’s Guide to VPLUS VPLUS Enhancements VPLUS Enhancements There have been many changes and enhancements to VPLUS since version B.04.10. This section will briefly discuss some of the changes and enhancements and how they can be of use to the programmer.
-
A Programmer’s Guide to VPLUS VPLUS Enhancements screen order number is a relative number of the field on the form. For example, if there are five fields on a form and the programmer wants to place the cursor on the fourth field, the FIELDNUM parameter would contain a “-4”. On the other hand, if the FIELDNUM parameter is positive, it implies field number creation order. This number is assigned to the field when the field is created through FORMSPEC.
-
A Programmer’s Guide to VPLUS VPLUS Enhancements VPLUS/V Reference Manual describes how to use batch mode FORMSPEC. Three new commands are available to the programmer: • FIELD - This command allows, several field attributes to be updated in batch mode. Any of the following can be changed: field name, field enhancements, field type, data type, initial value. • RENUMBER - This command reassigns field numbers to their screen order numbers.
-
A Programmer’s Guide to VPLUS VPLUS Enhancements User Environment Control File (Introduced on VPLUS B.04.20 in MPE G.02.01) With VPLUS version B.04.20 introduced in MPE G.02.01, there is an MPE file called VENVCNTL.PUB.SYS which is opened and read on the VOPENTERM call. Currently, the VPLUS USER ENVIRONMENT CONTROL file can control two items when VOPENTERM is executed. Two options have been implemented for the user environment control file. • The first option is an abbreviated terminal query.
-
A Programmer’s Guide to VPLUS VPLUS & Multiplexers VPLUS & Multiplexers Using VPLUS on a Pad-Terminal(Connected to a Cluster Controller HP 2334A) What is a CLUSTER CONTROLLER? When you use a Packet Switching Network (PSN) for data communication, you need equipment to do the packing and unpacking of the data at both ends. A CLUSTER normally will receive the packets for different users, unpack them and change the transmission mode from synchronous to asynchronous.
-
A Programmer’s Guide to VPLUS VPLUS & Multiplexers First we will describe the minor differences between using the terminal directly to an ADCC / ATP port on an HP 3000, or to a port on a PAD (HP 2334A). 1. Terminal configuration when used to a direct line (ADCC / ATP): Figure L-3. Direct Connection to an ATP- or ADCC-Port Term Terminal LP A A T / D P C C . . . . HP 3000 Modem DATACOMM : BaudRate : line speed (9600, 4800, 2400, 1200, ..
-
A Programmer’s Guide to VPLUS VPLUS & Multiplexers 2. When you want to connect the terminal to an HP 2334A CLUSTER (PAD) you must change the following specifications: DATACOMM: RecvPace XmitPace : Xon/Xoff : Xon/Xoff use XON/XOFF handshake on send and receive transmission. TERMINAL : InhHndShk : YES Inh DC2 : YES disables the use of DC1and of DC1/DC2/DC1handshake on blockmode. With the reconfiguration of the terminal you switch off the handshake normally used.
-
A Programmer’s Guide to VPLUS VPLUS & Multiplexers VPLUS TERMINAL USER -----------------------I------------I----------------------------. . send a FORM ---------->. . . . FORM is ready, . . data can be . . entered . . DC1------------------->. . . . . . The User can . .<--------- start typing. . . . .<------ ENTER or Function-key . . .Data is ready .to be . .transmitted . <----------------------.DC2 . . . VPLUS is ready . . to receive the . . data . . DC1------------------->. . . . .Terminal sends .
-
A Programmer’s Guide to VPLUS VPLUS & Multiplexers to do the DC1/DC2/DC1-handshake. When using TERM=24, the application first will set the InhHndShk=Y and the InhDC2=YES with the escape-sequence ‘esc&s1h1G’. You should set this before you start the session, but if you forgot, VPLUS will do it for you (but other things could go wrong, so it’s better to do it yourself to be sure!). This sequence will switch off all handshakes. After this, the terminal will be checked like usual.
-
A Programmer’s Guide to VPLUS VPLUS & Multiplexers This problem is solved by using ‘term=24’ in the logon. If you want to use VPLUS applications on a specified PADTERM, you can configure the terminal type in the system configuration to be ‘24’. This will switch on the correct blockmode handling for every user on this logical device.
-
A Programmer’s Guide to VPLUS Optimizing VPLUS Utilization Optimizing VPLUS Utilization VPLUS, Hewlett-Packard’s standard terminal management software, finds wide use in applications ranging from manufacturing control to financial transaction processing. Offered as part of the HP3000 Fundamental Operating Software (FOS), VPLUS provides programmers and designers access to the features of HP block-mode terminals, effectively insulating programs from the details of data communication and terminal control.
-
A Programmer’s Guide to VPLUS Optimizing VPLUS Utilization needs to access at one time. Assuming there is enough information to fill the screen, does one want to show it all at once. Too much data may overwhelm the user, making data entry more difficult due to a crowded and confusing screen. Presenting data in small doses may frustrate the user as he moves through multiple forms to see all the data, making data entry that much longer.
-
A Programmer’s Guide to VPLUS Optimizing VPLUS Utilization displayed is similar in format, it’s possible to use forms families to make minor changes in the display without repainting the entire screen. You can also use the intrinsic VCHANGEFIELD (released with version B.04.17 of VPLUS) to accomplish the same ends. Combining Several Forms If your program accesses several forms files, you should seriously consider combining them into a single file.
-
A Programmer’s Guide to VPLUS Optimizing VPLUS Utilization buffers. For example, suppose most forms in the forms file contain 20 2-character long fields, while one form contains 40 6-character long fields. Whereas most of the forms would only require the DBUF and IBUF to be 40 characters long (20 fields times 2 characters per field), VPLUS will allocate 240 characters for both buffers (40 times 6).
-
A Programmer’s Guide to VPLUS VPRINTSCREEN Intrinsic VPRINTSCREEN Intrinsic A new intrinsic, VPRINTSCREEN, provides the capability to print the entire contents of a terminal screen during VPLUS execution. Currently, VPLUS provides the intrinsic VPRINTFORM which prints the current form with the data contained in the form data buffer; function keys, appended forms, line drawing characters, etc., are not printed. With VPRINTSCREEN, these limitations no longer exist.
-
A Programmer’s Guide to VPLUS VPRINTSCREEN Intrinsic VPRINTSCREEN VPRINTSCREEN records the contents of the current screen to an off-line list device. A documentation option allows formatting for printing to a laser printer (See Modes of Operation). A VPLUS supported terminal is required during execution. TDP is required for the laser printer output.
-
A Programmer’s Guide to VPLUS VPRINTSCREEN Intrinsic A user may change any of these characteristics with a :FILE command. It is recommended that VPRINTSCREEN and VPRINTFORM not be used together within the same program. Since the same list file is used for both listings, output from the two calls will be intermixed. Another visible difference between VPRINTFORM and VPRINTSCREEN is that VPRINTFORM gives you the option to underline fields. This option is NOT available with VPRINTSCREEN (LP mode).
-
A Programmer’s Guide to VPLUS VPRINTSCREEN Intrinsic Printing Screens from TDP By default, EPOCLIST uses the VSETUP file to reference the supplied environment files. These files must be accessible by TDP before EPOCLIST can be printed. If a different environment file is used, EPOCLIST must be modified to reference the appropriate environment file. In addition, the font definitions from VENV80 and VENV88 must be included in the environment file used. (Refer to the fonts listed in the Limitations section).
-
A Programmer’s Guide to VPLUS VPRINTSCREEN Intrinsic The first step is to separate the screens in EPOCLIST. VEPOCUSE can be used to do this by following these steps: 1. :RUN TDP. Clear workspace. 2. USE VEPOCUSE. Answer the prompts: filename, number of occurrences, and desired PREFIX. VEPOCUSE will then split the file into ‘n’ files, all prefixed with the PREFIX entered. 3. Text in your document, and include the appropriate screen file in the appropriate location.
-
A Programmer’s Guide to VPLUS VPRINTSCREEN Intrinsic The Environment Files • Native Language support is NOT available for VPRINTSCREEN. To print a screen in another language, a LOCALIZED environment file must map to the following fonts: c = full bright g = half bright inverse video d = normal l = line draw m = math • There is no distinction between fullbright and halfbright provided with the current environment files. However, the code is set up to distinguish between them. (See the above fonts).
-
A Programmer’s Guide to VPLUS VPRINTSCREEN Intrinsic VSETUP This is a TDP “include” file which selects and sets up the proper environment for the printer selected. This file should be modified so the references to VENV80 and VENV88 are properly qualified by the GROUP.ACCOUNT they reside in. If the document you are printing resides in a separate group and account from VSETUP, then a file equation must be issued to reference VSETUP. This also applies if the user renames the VSETUP file to a local name.
-
A Programmer’s Guide to VPLUS VPRINTSCREEN Intrinsic Key 1 = FIRST FORM Key 2 = not defined Key 3 = PRINT Key 4 = REFRESH Key 5 = PREV FORM Key 6 = NEXT FORM Key 7 = SELECT FORM Key 8 = EXIT Appendix L 681
-
A Programmer’s Guide to VPLUS VPRINTSCREEN Intrinsic 682 Appendix L
-
Application Notes M Application Notes This appendix contains a number of application notes which are also posted on the KMINE web site. They represent some of the most frequently asked questions ( and the answers) about VPLUS . There are hundreds of similar notes and articles posted to KMINE. KMINE is a large database of problems and solutions which is accessible by both HP staff and customers. It is searchable by key word topics.
-
Application Notes Workarounds for VPLUS Forms Fille 32767 Record Limit Workarounds for VPLUS Forms Fille 32767 Record Limit Problem Description When trying to add a form to my forms file in FORMSPEC, I get an INTEGER OVERFLOW error. I understand that this is due to the forms file record limit of 32767 (see RCEN [W1331556/RCEN/English] ). How can I add my new form ? Solution There are three solutions to the 32767 record limitation for VPLUS forms files: 1. Use two forms files.
-
Application Notes Using the VPLUS Environment Control File (VENVCNTL) Using the VPLUS Environment Control File (VENVCNTL) Problem Description What is the VENVCNTL.PUB.SYS file on my system, and what is it used for? Solution The VPLUS environment control file, VENVCNTL, allows applications to override specific VPLUS defaults. VPLUS always checks for the existence of VENVCNTL.PUB.SYS or, alternatively, the existence of a file equated to this formal file designator.
-
Application Notes Using the VPLUS Environment Control File (VENVCNTL) Byte Explanation Side Effects / Comments 6 (MPE V/E only) VPLUS extends terminal status reads to ensure that input termination character is accounted for. DO NOT ACTIVATE this option unless experiencing VPLUS ”terminal status request failed” errors due to network delays. 7 Diagnostic only. 8 VPLUS does not force 7009x terminals to 80 columns. 9 VTURNON and VTURNOFF do notreset terminal function keys to default strings.
-
Application Notes How to Trace VPLUS calls in the Program While it is Running How to Trace VPLUS calls in the Program While it is Running Problem Description How can you track the VPLUS calls in the program as they are being executed? Solution To produce a record of VPLUS calls from a program as they are called, use the following: :SETJCW VIEWTRACE=1 :FILE TRCFILE;DEV=LP :RUN progname;STDLIST=*TRCFILE The file equation for TRCFILE could as easily be used for a disc file or for display to another terminal
-
Application Notes How to Redirect $STDLIST in a VPLUS Application How to Redirect $STDLIST in a VPLUS Application Problem Description Whenever my VPLUS program gets error messages those messages are displayed in the unprotected fields on the screen.
-
Application Notes FORMSPEC Gives FS Error -99 at Compile Time FORMSPEC Gives FS Error -99 at Compile Time Problem Description When trying to compile my formsfile, I receive the following error: FS ERROR -99 What does this mean? Solution The FS error -99, is a FormSpec error. This error means your formsfile is at end-of-file (eof). To verify this, do a :LISTF formsfile_name,2 and look at the EOF and LIMIT. If they are the same or very close, this is the reson you are getting this error.
-
Application Notes FORMSPEC Gives FS Error -99 at Compile Time 690 Appendix M
-
Index A Access to data, 32 Add Check Digit option, REFSPEC, 221 ADDARBFIELD in ARB batch mode, 390 ADDARBSCREEN in ARB batch mode, 391 Adding a reformat, REFSPEC, 198 Adjust menu, 618 Advanced forms design, 125 Advanced processing, 30, 157 altering forms sequence, 157 data formatting, 157 data movement, 157 processing phases, 157 Advanced Processing Statements, 31 Alphabetic check digits, 582 altering forms sequence, 157 Application-Ready Buffer, 32 Applications programmer, 37 Applications programmer, usin
-
Index LOCALEDITS, 140 Constant output file, REFSPEC, 211 control file, 609 Control statements, 133 Controlling the bell, 357 Conversion bit map, 621 of data, REFSPEC, 214 output data to EBCDIC, REFSPEC, 204 Conversion during data movement, 163 converting, 616 Converting forms file, 616 COPY in FORMSPEC batch mode, 375 Creating an ARB with FORMSPEC, 109 Cursor, 322 Cursor placement, 322 Cursor positioning, 660 D Data combining, 187 entering, 47 interpreting type, 69 modifying, 51 program-generated, 48 separ
-
Index Errors correcting, 49 logic, 49 system, 49 EXIT in FORMSPEC batch mode, 377 EXIT key REFSPEC, 194 F FAIL statement FORMSPEC, 174 FIELD in FORMSPEC batch mode, 378 Field length, 65 name, 66 number, 65 REFSPEC Output Field Menu, 213 separator, REFSPEC, 205 specifications, REFSPEC, 187 specifying initial value, 72 tags, 64 type, 67 Field edits, 157 date handling, 404 numeric data, 404 Field eidts native language characters, 404 Field enhancement, 28 Field length REFSPEC output field, 213 Field menu, 100
-
Index Forms families, 87, 252 Forms family example, 87 Forms file compiling, 83 converting, 616 designing, 584 expanding, 83 listing, 84 purging, 616 renaming, 616 Forms file interface, 32 Forms file menu REFSPEC, 197 Forms file prototype, 81 Forms file size, 79 Forms modification, 79 Forms sequence, 45 Forms sequencing, 31, 73 next form option, 74 repeat option, 73 FORMSPEC, 26, 54 creating an ARB, 109 file menu, 54 function keys, 55 invoking in batch mode, 371 key labels, 56 menu sequence, 56 reserved wo
-
Index HPPA, 626 Intrinsics dependencies, 257 Intrinsics functions, 254 J JUSTIFY, 218 JUSTIFY statement FORMSPEC, 166 Modified data tag, 594 Modifying data, 52 Modulus 10 calculations, 580 Modulus 11 calculations, 581 MOVEARBFIELD in ARB batch mode, 396 Moving data SET statement, 159 Multiplexer, 664 K Key label area, 232, 234 Keyboard control, 357 KSAM, 616 KSAM forms file, 616 N Native Language identifier, 403 NLS language attribute, 402 Numeric type, 161 L Language attribute, 402 Length check, 145 L
-
Index Precision architecture, 623 Preload of forms, 357 Print VPRINTFORM, 324 VPRINTSCREEN, 326 Printing forms and data, 42 Processing phases configuration, 157 field edits, 157 finish form, 157 initialization, 157 Processing specifications for configuration, 137 Processing specifications for field edits, 144 Processing statements, 141 Program Interface intrinsics, 32 Program interruption, 608 Programmer’s guide, 647 Purging, 616 Purging forms, 252 Purging forms file, 616 R Range checks, 149 REFORMAT, 181,
-
Index Status/Error control, 33 STOP statement FORMSPEC, 175 Streaming REFORMAT, 224 STRIP statement FORMSPEC, 165 Supported terminals, 594 Syntax, 129 System crash, 323 T Table checks, 148 Terminal buffer configuration, 607 communication area, 605 Terminal configuration, 624 Terminal features, 250 Terminal interface, 32 Terminal/language selection menu, 119 Terminals, 593 color enhancement, 597 data capture device, 597 X.