Form SAMPLE_CHECKING_ACCOUNT /* * * COPYRIGHT (c) 1988 - 1996 BY * DIGITAL EQUIPMENT CORPORATION, MAYNARD, MASS. * * THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE USED AND COPIED * ONLY IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE AND WITH THE * INCLUSION OF THE ABOVE COPYRIGHT NOTICE. THIS SOFTWARE OR ANY OTHER * COPIES THEREOF MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY * OTHER PERSON. NO TITLE TO AND OWNERSHIP OF THE SOFTWARE IS HEREBY * TRANSFERRED. * * THE INFORMATION IN THIS SOFTWARE IS SUBJECT TO CHANGE WITHOUT NOTICE * AND SHOULD NOT BE CONSTRUED AS A COMMITMENT BY DIGITAL EQUIPMENT * CORPORATION. * * DIGITAL ASSUMES NO RESPONSIBILITY FOR THE USE OR RELIABILITY OF ITS * SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPLIED BY DIGITAL. */ /* This is the form for the DECforms Sample Checking Application. * It is intended to show more features than the simple sample program. */ /* The following form data is used to set the value of OPERATOR_CHOICE from the * various menu leaves. */ Form Data ACCOUNT_NUMBER Unsigned Longword ACCOUNT_PAD Character(2) /* Padding for VAX/AXP */ AMOUNT Unsigned Longword /* Kept in pennies */ CHECKING_BALANCE Unsigned Longword /* Kept in pennies */ CHECK_MEMO Character(35) /* Only for check, not saved*/ CHECK_NUMBER Unsigned Word CHOICE_PAD Unsigned Byte /* Padding for VAX/AXP */ CITY Character(20) CURRENT_DATE Datetime(8) TEMP_CURRENT Adt Current DATE_ESTABLISHED Datetime(8) FIRST_NAME Character(15) HOME_PHONE Integer(10) LAST_NAME Character(20) MAIL_CSZ Character(30) /* City, address, zip for mailing address on check */ MAIL_NAME Character(39) /* Name for mailing label */ MEMO Character(35) /* Memo returned to program */ MIDDLE_NAME Character(15) NEXT_UPDATE_MESSAGE Character(80) Varying Value "" /* Message to be put out when next update comes in */ NEXT_UPDATE_AMOUNT Character(35) Varying Value "" /* Value put out when next update come in */ OPERATOR_CHOICE Unsigned Byte OP_PASSWORD Character(12) Value " " /* Entry from operator */ PASSWORD Character(12) /* Real password */ ROOM_IN_REG Unsigned Byte Value 1 /* 1 so initial display ok */ SAVINGS_BALANCE Unsigned Longword /* Kept in pennies */ STATE Character(2) STREET Character(30) UPDATE_PAD Unsigned Byte /* Padding for VAX/AXP */ WORK_PHONE Integer(10) ZIP_CODE Character(5) /* Special, built-in form data items * CURRENTITEM is the name of the current field into which the operator is * entering data * FIELDIMAGE is the image of the current field * * FUNCTIONNAME is the name of the last entered function * LOCATORITEM is the name of the item pointed to by the locator (windows layouts only) */ End Data Form Data CURRENTITEM Character(20) Varying Builtin FIELDIMAGE Character(35) Varying Builtin FUNCTIONNAME Character(35) Varying Builtin LOCATORITEM Character(35) Varying Builtin /* Variables used to call the system service routines as procedural escape unit * and the returned values for the state of the VMS process. These are supplied * as an example of calling RTL routines as procedural escapes. */ USERNAME Character(20) VERSION Character(30) /*This data is used for the pixel layouts. Pixel layouts allow some of the panels to stick around for a while and don't always revert to the main menu. We '- 'want to keep the data in those panels and not have them interfere with each other. So, we have to have different amounts and memos for the three types of panels: check, deposit, and transfer. When the user says okay on those panels, we copy their values to the variables that will be returned to the program in the record.*/ End Data Form Data CHECK_PANEL_AMOUNT Unsigned Longword /* Kept in pennies */ DEPOSIT_PANEL_AMOUNT Unsigned Longword /* Kept in pennies */ TRANSFER_PANEL_AMOUNT Unsigned Longword /* Kept in pennies */ CHECK_PANEL_MEMO Character(35) DEPOSIT_PANEL_MEMO Character(35) TRANSFER_PANEL_MEMO Character(35) CHECK_FIELDIMAGE Character(30) Varying DEPOSIT_FIELDIMAGE Character(30) Varying TRANSFER_FIELDIMAGE Character(30) Varying CHECK_PANEL_VISIBLE Unsigned Byte Value 0 DEPOSIT_PANEL_VISIBLE Unsigned Byte Value 0 TRANSFER_PANEL_VISIBLE Unsigned Byte Value 0 ACCOUNT_PANEL_VISIBLE Unsigned Byte Value 0 /* REGISTER data. Thirty register occurrences are kept in data. * ENTRY_COUNT tells how many of the thirty occurrences sent are non-null. */ End Data Form Data REGISTER_FIRST Unsigned Word /*Number of first entry displayed*/ ENTRY_COUNT Unsigned Word /*Number non-null entries in reg*/ Group REGISTER Occurs 30 REG_CHK_NUM Unsigned Word /*Number for check*/ REG_DATE Datetime(8) /*Date of entry*/ REG_MEM Character(35) /*Memo for transaction*/ REG_AMOUNT Longword Integer /*Amount of transaction*/ REG_PAY Longword Integer /*Amount of transaction*/ REG_BALANCE Unsigned Longword /*Balance after transaction*/ REG_TAX_DED Unsigned Byte /*Tax deduction:0=no,>0=yes*/ End Group End Data Form Data VALUE_EXIT Word Integer Value 1 VALUE_CHECK Word Integer Value 2 VALUE_DEPOSIT Word Integer Value 3 VALUE_CASH Word Integer Value 4 VALUE_TRANSFER Word Integer Value 100 VALUE_XFER_TO_SAV Word Integer Value 5 VALUE_XFER_TO_CHK Word Integer Value 6 VALUE_REVIEW Word Integer Value 101 VALUE_REV_REG Word Integer Value 7 VALUE_REV_ACCOUNT Word Integer Value 8 /* These form data items are used for display of buttons on the * transfer menu. */ End Data Form Data TO_SAVINGS_BUTTON Character(1) Value "O" TO_CHECKING_BUTTON Character(1) Value "O" End Data Form Record ACCOUNT /* * The ACCOUNT record is used by either SEND or RECEIVE from the * program. It is sent at the beginning of the program to set the * form storage variables. It is received when account updating * is to be done. */ ACCOUNT_NUMBER Unsigned Longword DATE_ESTABLISHED Datetime(8) ZIP_CODE Unsigned Longword LAST_NAME Character(20) FIRST_NAME Character(15) MIDDLE_NAME Character(15) STREET Character(30) CITY Character(20) STATE Character(2) HOME_PHONE Integer(10) Implicit Sign WORK_PHONE Integer(10) Implicit Sign PASSWORD Character(12) ACCOUNT_PAD Character(2) End Record Form Record MAIL_FORMAT /* * MAIL_FORMAT is a reformatting of the name and last address line * as they would appear on a mailing label, with extra spaces * squeezed out. This record is used only by a SEND from the program. */ MAIL_NAME Character(39) MAIL_CSZ Character(30) End Record Form Record UPDATE /* * UPDATE is sent whenever the register is changed. This means * the account balance and the check number also changes. * It is used only by a SEND from the program. */ CHECKING_BALANCE Unsigned Longword /*passed as pennies*/ SAVINGS_BALANCE Unsigned Longword /*passed as pennies*/ CHECK_NUMBER Unsigned Word ROOM_IN_REG Unsigned Byte /*1=>yes, 0=no>*/ UPDATE_PAD Unsigned Byte /* Padding for VAX/AXP */ End Record Form Record CHOOSE /* * CHOOSE is used only by a RECEIVE to request a choice from the operator. */ OPERATOR_CHOICE Longword Integer AMOUNT Longword Integer /*Signed, passed as pennies*/ CURRENT_DATE Datetime(8) MEMO Character(35) CHOICE_PAD Unsigned Byte /* Padding for VAX/AXP */ End Record Form Record REGISTER_RECORD /* * REGISTER_RECORD information record. Thirty register records are * sent from the program. * * The record actually transfers the "amount" of each entry as a * signed number, reg_amount(n). We want to display this in one of two places: * as a deposit or as a withdrawal, based on its sign; the most convenient * way to do this is to copy the amount to another data item: reg_pay(n). * The field displays for these two data items then decides whether to display * the number or to display blanks. */ ENTRY_COUNT Unsigned Longword Group REGISTER Occurs 30 REG_CHK_NUM Unsigned Longword REG_DATE Datetime(8) REG_AMOUNT Longword Integer Source REGISTER.REG_AMOUNT Destination REGISTER.REG_AMOUNT Destination REGISTER.REG_PAY REG_BALANCE Unsigned Longword REG_MEM Character(35) REG_TAX_DED Unsigned Byte End Group End Record Layout CHECKING_LAYOUT Device Terminal DECVT /* %VT100 includes newer terminals such */ /* as VT200, VT300, LK201 keys,... */ Type %VT100 End Device Units Characters Size 24 Lines by 80 Columns List STATE_LIST Exactcase "AL" "AK" "AZ" "AR" "CA" "CO" "CT" "DE" "DC" "FL" "GA" "HI" "ID" "IL" "IN" "IA" "KS" "KY" "LA" "ME" "MD" "MA" "MI" "MN" "MS" "MO" "MT" "NE" "NV" "NH" "NJ" "NM" "NY" "NC" "ND" "OH" "OK" "OR" "PA" "RI" "SC" "SD" "TN" "TX" "UT" "VA" "VT" "WA" "WV" "WI" "WY" End List Viewport TOP_VP Lines 1 Through 3 Columns 1 Through 80 End Viewport Viewport MID_VP Lines 3 Through 20 Columns 1 Through 80 End Viewport Viewport WELCOME_VP Lines 1 Through 20 Columns 1 Through 80 End Viewport Viewport MESSAGE_VP Lines 23 Through 24 Columns 1 Through 80 End Viewport Viewport BALANCE_VP Lines 21 Through 22 Columns 1 Through 80 End Viewport Viewport HELP_VP Lines 6 Through 22 Columns 1 Through 80 End Viewport Viewport CASH_VP Lines 3 Through 9 Columns 33 Through 40 End Viewport Viewport TRANSFER_VP Lines 3 Through 9 Columns 43 Through 75 End Viewport Viewport REVIEW_VP Lines 3 Through 7 Columns 57 Through 74 End Viewport Function PRINT_FUNCTION Is %PF4 End Function Function QUIT Is %F8 (%PF1 %CAPITAL_Q) (%PF1 %SMALL_Q) End Function Function SELECT Is %SELECT %F10 (%PF1 %CAPITAL_E) (%PF1 %SMALL_E) %CONTROL_D %CONTROL_Z End Function Function UP ITEM Is %UP End Function Function DOWN ITEM /* Note: we don't define special functions for right and left arrows. * This form defines the boundary cursor right/left function * responses (see below for them). */ Is %DOWN End Function Enable Response /* EXTERNAL RESPONSES */ /* The enable response first welcomes the user, waits for acknowledgment, * and then puts up the top and bottom panels, which stay there forever. * As an example of how to call procedural escapes, we call some RTL * routines to find some VMS information about the process to put up on * the welcome_panel. */ Activate Wait on WELCOME_PANEL Call "forms_checking_getsysinfo_" Using /* VMS username returned */ /* VMS version returned */ /*Set the current date since CURRENT_DATE can't be declared with CURRENT attribute*/ By Descriptor USERNAME By Descriptor VERSION Let CURRENT_DATE = TEMP_CURRENT Request Exit Response Display CHOICE_PANEL BALANCE_PANEL Message "Use arrows to position to choice and press SELECT or" " Keypad-period." End Response End Response Disable Response /* The DISABLE response waves a fond farewell */ Remove All Display FAREWELL_PANEL End Response Send Response UPDATE /* The UPDATE send response causes the NEXT_UPDATE_MESSAGE to be output * to the message panel. This message was set by the last transaction that * caused an update to occur. There might not be any message so check * first. Also, clear that message so it doesn't come through next time. * * Secondly, if the variable room_in_reg = 0, that means that no more * transactions affecting the register can be accepted, so tell the * operator. */ If (NEXT_UPDATE_MESSAGE <> "") Then Message NEXT_UPDATE_MESSAGE ": " NEXT_UPDATE_AMOUNT Reset NEXT_UPDATE_MESSAGE End If If (ROOM_IN_REG = 0) Then Message "The register is full, you can only do reviews now." Signal End If End Response Receive Response CHOOSE /* The OPERATOR_CHOICE response activates the top level menu. * After the first invocation, we would like the cursor to go to the * same top level menu choice it was on when the exchange completed or * was cancelled. We do this by querying the value of operator_choice * this is the value last passed to the program as to what the operator's * choice was. */ Activate /* Don't have to worry about check, since that's where the cursor * will go by default, so we can start checking for deposit */ Panel CHOICE_PANEL If (OPERATOR_CHOICE = VALUE_DEPOSIT) Then Position To Icon CHOICE_DEPOSIT On CHOICE_PANEL End If If (OPERATOR_CHOICE = VALUE_CASH) Then Position To Icon CHOICE_CASH On CHOICE_PANEL End If If ((OPERATOR_CHOICE = VALUE_XFER_TO_SAV) OR (OPERATOR_CHOICE = VALUE_XFER_TO_CHK)) Then Position To Icon CHOICE_TRANSFER On CHOICE_PANEL End If If ((OPERATOR_CHOICE = VALUE_REV_REG) OR (OPERATOR_CHOICE = VALUE_REV_ACCOUNT)) Then Position To Icon CHOICE_REVIEW On CHOICE_PANEL End If End Response Receive Response ACCOUNT /* Receive response for account information activates entire account * panel, including the op_password field. */ Activate Panel ACCOUNT_PANEL End Response Transceive Response REGISTER_RECORD REGISTER_RECORD /* REGISTER record. * For a register transceive, we want to let the operator get at only * those fields which have meaning -- non-null register entries. The * default response would activate all register entries. * * Position to the last field, since people usually want to access the * most recent stuff first. */ Activate Field REGISTER(1:ENTRY_COUNT).REG_TAX_DED on REGISTER_PANEL Position To Last Item End Response Function Response TERMINATE HELP /* Non-external responses */ /* When we EXIT HELP, we need to remove the viewport containing the * help text. We do this explicitly here, instead of using the REMOVE * clause in the help panels. This makes the displays between one * help panel and the next smoother. This is true only for character * cell layouts. */ Remove HELP_VP Exit Help End Response Function Response TRANSMIT /* This is exactly the same as the default response for TRANSMIT * except that it removes the HELP VIEWPORT when we are exiting * from HELP. (See comments above on TERMINATE HELP response). */ If HELP ACTIVE Then Remove /* <-- This step is different from the default */ HELP_VP Exit Help Else Return End If End Response Function Response PRINT_FUNCTION /* If the PRINT_FUNCTION is entered at any place except the panels * which have it defined, it is meaningless. */ Message "The print function is not active for this option" Signal End Response Function Response BOUNDARY CURSOR LEFT /* These are special function responses that recognize the special case * of the cursor being at the boundary of the field or icon (the cursor is * always at the boundary of an icon since it doesn't allow data entry). * In this special case, we change the cursor from moving within the field * to move right or left to the next field or icon. */ If LEFTMOST ITEM Then Message %NO_LEFT_ITEM Else Position Immediate To Left Item End If End Response Function Response BOUNDARY CURSOR RIGHT If RIGHTMOST ITEM Then Message %NO_RIGHT_ITEM Else Position Immediate To Right Item End If End Response Use Help Panel KEYS_HELP Message Panel MESSAGE_PANEL Viewport MESSAGE_VP /* The remaining panels are listed in alphabetical order, except the * help panels which are alphabetized separately at the end. */ End Panel Panel ACCOUNT_PANEL Viewport MID_VP Display %Keypad_Application /* ACCOUNT_PANEL shows the account information and allows entry of * new account information if the password is entered correctly. */ Exit Response Remove MID_VP Let NEXT_UPDATE_MESSAGE = "" End Response Function Response QUIT Message "Quitting -- no update made to personal information." Return Immediate "EFQUT" End Response Function Response PREVIOUS PANEL Message "Press F8 or PF1-Q to cancel the update." End Response Function Response NEXT PANEL Message "Press F8 or PF1-Q to cancel the update or " Message " F10 or PF1-E to update your personal record." End Response Use Help Panel ACCOUNT_PANEL_HELP Apply Field Default Of Active Highlight Reverse Minimum Length 1 Message "You must enter something for " CURRENTITEM End Default Literal Text Line 2 Column 27 Value "Account Data" Display Font Size Double Wide End Literal Literal Text Line 4 Column 18 Value "Enter secret password to change the account data:" End Literal Field OP_PASSWORD Same Line Next Column +1 Entry Response Reset OP_PASSWORD End Response Concealed Input Picture X(12) Use Help Message "Enter the secret word to change the account data." " (Hint: try Help again.)" Require (OP_PASSWORD = PASSWORD) Message "You must enter the right password to change the data. " "Hint: press the HELP key." End Field Literal Rectangle Line 5 Column 2 Line 17 Column 77 End Literal Literal Text Line 6 Column 49 Value "Account Number " End Literal Field ACCOUNT_NUMBER Same Line Next Column Output Picture 9(5) Protected End Field Literal Text Next Line Column 49 Value "Opened" End Literal Field DATE_ESTABLISHED Same Line Next Column +4 Output Picture For Date NN/DD/YYYY Protected End Field Literal Text Line 6 Column 4 Value "NAME" End Literal Literal Text Same Line Column 9 Value "Last" End Literal Field LAST_NAME Same Line Column 16 Display Underlined Output Picture X(20) End Field Literal Text Next Line Column 9 Value "First" End Literal Field FIRST_NAME Same Line Column 16 Display Underlined Output Picture X(15) End Field Literal Text Next Line Column 9 Value "Middle" End Literal Field MIDDLE_NAME Same Line Column 16 Display Underlined Output Picture X(15) No Minimum Length End Field Literal Text Next Line +1 Column 4 Value "ADDRESS" End Literal Literal Text Next Line Column 9 Value "Street" End Literal Field STREET Same Line Column 16 Display Underlined Output Picture X(30) End Field Literal Text Next Line Column 9 Value "City" End Literal Field CITY Same Line Column 16 Display Underlined Output Picture X(20) End Field Literal Text Next Line Column 9 Value "State" End Literal Field STATE Same Line Column 16 Display Underlined Output Picture X(2) Uppercase Minimum Length 2 Message "State field must be two letters" Search STATE_LIST Message "Must be one of the fifty states or DC." End Field Literal Text Same Line Next Column +4 Value "Zip" End Literal Field ZIP_CODE Same Line Next Column +2 Display Underlined Output Picture 9(5) Require (ZIP_CODE >= 100) Message "Zip code region must be at least 1; " "that means the zip code must be 100 or more." End Field Literal Text Line 10 Column 49 Value "PHONE" End Literal Literal Text Line 11 Column 53 Value "Home" End Literal Field HOME_PHONE Same Line Column 63 Display Underlined Output Picture '('999')'999'-'9999 Minimum Length 10 Message "You must supply home phone number, " "including area code." End Field Literal Text Next Line Column 53 Value "Business" End Literal Field WORK_PHONE Same Line Column 63 Function Response NEXT ITEM Message "Press F10 or PF1-E to update your account record." End Response Display Underlined Output Picture '('999')'999'-'9999 No Minimum Length Range 0 Through 0 1000000000 Through 9999999999 Message "Business phone must be null or all 10 digits" End Field Literal Text Line 15 Column 7 Value "To record new account data and return to the menu, "- "press F10 or PF1-E." End Literal Literal Text Next Line Same Column Value "To return to the menu without changing the data, press "- "F8 or PF1-Q." End Literal End Panel Panel BALANCE_PANEL Viewport BALANCE_VP /* BALANCE_PANEL always shows the balances. */ Literal Text Line 1 Column 40 Value "Balances: Checking:" End Literal Field CHECKING_BALANCE Same Line Next Column +1 Output Picture 99,999,99W9.99 Scale -2 Protected End Field Literal Text Next Line Column 50 Value "Savings: " End Literal Field SAVINGS_BALANCE Same Line Next Column +1 Output Picture 99,999,99W9.99 Scale -2 Protected End Field End Panel Panel CASH_PANEL Viewport CASH_VP Display %Keypad_Application /* CASH_PANEL gets the choices for the cash withdrawal */ Exit Response /* Put these 3 assignments here to avoid doing them for each choice. */ Let OPERATOR_CHOICE = VALUE_CASH Let MEMO = "*Cash withdrawal*" Let NEXT_UPDATE_MESSAGE = "Cash withdrawal made against your "- "checking account" Deactivate Panel CASH_PANEL Remove CASH_VP Position To Previous Item End Response Function Response QUIT Message "Quitting -- no cash withdrawn." Deactivate Panel CASH_PANEL Position Immediate To Previous Item /*Causes exit & deactivate*/ End Response Function Response NEXT ITEM If ( NOT PANEL LAST ITEM) Then Position To Next Item End If End Response Function Response BOUNDARY CURSOR RIGHT Position To Down Item End Response Function Response BOUNDARY CURSOR LEFT Position To Up Item End Response Function Response UP ITEM If UPPERMOST ITEM Then Position To Previous Item /* which is on previous panel */ Else Position To Up Item End If End Response Use Help Panel CASH_PANEL_HELP Literal Rectangle Line 1 Column 1 Line 7 Column 8 End Literal Literal Text Line 1 Column 2 Value " Cash " Display Reverse End Literal Icon CHOICE_CASH_10 Function Response SELECT Let AMOUNT = 1000 Let NEXT_UPDATE_AMOUNT = "$10" Return End Response Active Highlight Reverse Concealed When (CHECKING_BALANCE < 1000) Protected When (CHECKING_BALANCE < 1000) Literal Text Line 3 Column 2 Value " $10" End Literal End Icon Icon CHOICE_CASH_20 Function Response SELECT Let AMOUNT = 2000 Let NEXT_UPDATE_AMOUNT = "$20" Return End Response Active Highlight Reverse Concealed When (CHECKING_BALANCE < 2000) Protected When (CHECKING_BALANCE < 2000) Literal Text Next Line Same Column Value " $20" End Literal End Icon Icon CHOICE_CASH_50 Function Response SELECT Let AMOUNT = 5000 Let NEXT_UPDATE_AMOUNT = "$50" Return End Response Active Highlight Reverse Concealed When (CHECKING_BALANCE < 5000) Protected When (CHECKING_BALANCE < 5000) Literal Text Next Line Same Column Value " $50" End Literal End Icon Icon CHOICE_CASH_100 Function Response SELECT Let AMOUNT = 10000 Let NEXT_UPDATE_AMOUNT = "$100" Return End Response Active Highlight Reverse Concealed When (CHECKING_BALANCE < 10000) Protected When (CHECKING_BALANCE < 10000) Literal Text Next Line Same Column Value " $100" End Literal End Icon End Panel Panel CHECK_PANEL Viewport MID_VP Display %Keypad_Application /* CHECK_PANEL is used for entry of check data and for printing * a copy of the check. */ Entry Response Reset MEMO AMOUNT CHECK_MEMO End Response Exit Response /* There two reasons we could be leaving the panel. QUIT : The operator pressed the QUIT key. There was a POSITION IMMEDIATE. We remove the viewport and deactivate the panel. TRANSMIT : We're done. In this case, we make some assignments for the record being sent back and for the action the next time the update record comes in. We get rid of the viewport, but keep the panel active, so that the validation on the fields occurs. */ Remove MID_VP If IMMEDIATE Then Deactivate Panel CHECK_PANEL Position Immediate To Previous Item Else Let OPERATOR_CHOICE = VALUE_CHECK Let NEXT_UPDATE_MESSAGE = "Check Paid" End If End Response Function Response QUIT Message "Quitting -- no check written." Position Immediate To Previous Panel End Response Function Response PRINT_FUNCTION Validate Panel CHECK_PANEL If ( NOT IMMEDIATE) Then /* print and return only if the check is okay */ Print CHECK_PANEL Message "The check has been printed to a file " Return End If End Response Function Response NEXT PANEL Message "Press F10 or PF1-E to finish the check." End Response Function Response PREVIOUS PANEL Message "Press F8 or PF1-Q to cancel the check." End Response Use Help Panel CHECK_PANEL_HELP Literal Rectangle Line 3 Column 1 Line 16 Column 79 End Literal Literal Text Line 2 Column 27 Value "Write a Check" Display Font Size Double Wide End Literal Field CHECK_NUMBER Line 4 Column 70 Output Picture 9999R9 Protected End Field Field MAIL_NAME Line 4 Column 3 Protected End Field Field STREET Next Line Same Column Protected End Field Field MAIL_CSZ Next Line Same Column Protected End Field Field HOME_PHONE Next Line Same Column Output Picture 'Home ('999')'999'-'9999 Protected End Field Field WORK_PHONE Same Line Column 22 Concealed When (WORK_PHONE = 0) Output Picture 'Office ('999')'999'-'9999 Protected End Field Literal Text Next Line Column 50 Value "Date:" End Literal Field CURRENT_DATE Same Line Next Column +1 Output Picture For Date MMMMMMMMMQ' 'DDQ', 'YYYY Protected End Field Literal Text Next Line +1 Column 4 Value "Pay to" End Literal Field MEMO /* Labelled "Pay to" field, returned to pgm as "memo" */ Same Line Next Column +1 Function Response PREVIOUS ITEM Message "Press F8 or PF1-Q to cancel the check." End Response Active Highlight Reverse Display Underlined Output Picture X(35) Use Help Message "Enter the person or organization to whom you" " wish to pay the check." Minimum Length 1 Message "You must fill in the payee." End Field Literal Text Same Line Column 60 Value "Amount $" End Literal Field AMOUNT Same Line Next Column Exit Response Let NEXT_UPDATE_AMOUNT = FIELDIMAGE End Response Active Highlight Reverse Output Picture 999,99R9.99 Scale -2 Replace Leading "*" Justification Decimal Use Help Message "Enter the amount to be paid." Range 0 Through CHECKING_BALANCE Message "Check amount must be less than the checking "- "account" " balance." Require (AMOUNT > 0) Message "Check amount must be greater than zero." End Field Literal Text Next Line +1 Column 4 Value "Memo" End Literal Field CHECK_MEMO Same Line Next Column +1 Function Response NEXT ITEM Message "Press F10 or PF1-E to finish the check." End Response Active Highlight Reverse Display Underlined Output Picture X(35) Use Help Message "Fill in a reminder to yourself about what the" " check is for. You need not fill this in." End Field Literal Text Next Line +2 Column 4 Value "FIRST NATIONAL BANK" End Literal Literal Text Same Line Column 60 Value "Account" End Literal Field ACCOUNT_NUMBER Same Line Next Column +1 Output Picture 9(5) Protected End Field Literal Text Line 17 Column 1 Value "Fill in the fields and terminate with F10 or PF1-E. "- "Cancel with F8 or PF1-Q." End Literal End Panel Panel CHOICE_PANEL Viewport TOP_VP Display %Keypad_Application /* CHOICE_PANEL is a label and menu always displayed at the * top of the screen. */ Function Response QUIT Position Immediate To Icon CHOICE_EXIT On CHOICE_PANEL Message "Press F10 or PF1-E to leave the application." End Response Function Response NEXT ITEM If LAST ITEM Then Position To First Item Else Position To Next Item End If End Response Function Response BOUNDARY CURSOR RIGHT If RIGHTMOST ITEM Then Position To First Item Else Position To Right Item End If End Response Function Response DOWN ITEM If RIGHTMOST ITEM Then Position To First Item Else Position To Right Item End If End Response Function Response PREVIOUS ITEM If FIRST ITEM Then Position To Last Item Else Position To Left Item End If End Response Function Response BOUNDARY CURSOR LEFT If FIRST ITEM Then Position To Last Item Else Position To Left Item End If End Response Function Response UP ITEM If FIRST ITEM Then Position To Last Item Else Position To Left Item End If End Response Use Help Panel CHOICE_PANEL_HELP Literal Text Line 2 Column 15 Value "Personal Checking Account" Display Font Size Double High End Literal Icon CHOICE_CHECK Function Response SELECT If (CHECKING_BALANCE = 0) Then Message "You can't write a check; you have a zero balance." Invalid Else Activate Panel CHECK_PANEL Position Immediate To Panel CHECK_PANEL End If End Response Active Highlight Reverse Concealed When (ROOM_IN_REG = 0) Protected When (ROOM_IN_REG = 0) Literal Text Line 3 Column 2 Value " Write a check... " End Literal End Icon Icon CHOICE_DEPOSIT Function Response SELECT Activate Panel DEPOSIT_PANEL Position Immediate To Panel DEPOSIT_PANEL End Response Active Highlight Reverse Concealed When (ROOM_IN_REG = 0) Protected When (ROOM_IN_REG = 0) Literal Text Same Line Column 20 Value " Deposit... " End Literal End Icon Icon CHOICE_CASH Function Response SELECT If (CHECKING_BALANCE < 1000) Then Message "You can't withdraw cash because your checking" " account balance is too small." Signal /* NOTE: we wouldn't have to bother with an ELSE '- 'on the above IF. * Since each field on the cash_panel is PROTECTED WHEN, no * field is unprotected when checking_balance<1000; so we'd put * the cash fields on the activation list, but POSITION would * have no effect. We could actually get by without the IF, * but customers would wonder why we couldn't select cash if * we didn't put out a message. However, we can save time by * avoiding the ACTIVATION and POSITION steps, so we do it. */ Else Activate Panel CASH_PANEL Position Immediate To Panel CASH_PANEL End If End Response Active Highlight Reverse Concealed When (ROOM_IN_REG = 0) Protected When (ROOM_IN_REG = 0) Literal Text Same Line Column 34 Value " Cash... " End Literal End Icon Icon CHOICE_TRANSFER Function Response SELECT Activate Panel TRANSFER_PANEL Position Immediate To Panel TRANSFER_PANEL End Response Active Highlight Reverse Concealed When (ROOM_IN_REG = 0) Protected When (ROOM_IN_REG = 0) Literal Text Same Line Column 44 Value " Transfer... " End Literal End Icon Icon CHOICE_REVIEW Function Response SELECT Activate Panel REVIEW_PANEL Position Immediate To Panel REVIEW_PANEL End Response Active Highlight Reverse Literal Text Same Line Column 58 Value " Review... " End Literal End Icon Icon CHOICE_EXIT Function Response SELECT Let OPERATOR_CHOICE = VALUE_EXIT Return End Response Active Highlight Reverse Literal Text Same Line Column 71 Value " Exit " End Literal End Icon End Panel Panel DEPOSIT_PANEL Viewport MID_VP Display %Keypad_Application /* DEPOSIT_PANEL is used for entering a deposit and for printing * a copy of the deposit slip. */ Entry Response Reset MEMO AMOUNT End Response Exit Response /* See the check panel for an explanation of this response */ Remove MID_VP If IMMEDIATE Then Deactivate Panel DEPOSIT_PANEL Position Immediate To Previous Item Else Let OPERATOR_CHOICE = VALUE_DEPOSIT Let NEXT_UPDATE_MESSAGE = "Deposit credited to your "- "checking account" End If End Response Function Response QUIT Message "Quitting -- no deposit has been made." Position Immediate To Previous Panel End Response Function Response PRINT_FUNCTION Validate Panel DEPOSIT_PANEL If ( NOT IMMEDIATE) Then /* print only if the deposit is okay */ Print DEPOSIT_PANEL Message "The deposit slip has been printed to a file " Return End If End Response Function Response NEXT PANEL Message "Press F10 or PF1-E to make the deposit." End Response Function Response PREVIOUS PANEL Message "Press F8 or PF1-Q to cancel the deposit." End Response Use Help Panel DEPOSIT_PANEL_HELP Literal Rectangle Line 3 Column 7 Line 10 Column 67 End Literal Literal Text Line 2 Column 25 Value "Deposit Record" Display Font Size Double Wide End Literal Literal Text Next Line +1 Column 10 Value "Date:" End Literal Field CURRENT_DATE Same Line Next Column +1 Output Picture For Date MMMMMMMMMQ' 'DDQ', 'YYYY Protected End Field Literal Text Same Line Column 52 Value "Account" End Literal Field ACCOUNT_NUMBER Same Line Next Column +1 Output Picture 9(5) Protected End Field Literal Text Next Line +2 Column 20 Value "Deposit $" End Literal Field AMOUNT Same Line Column 30 Exit Response Let NEXT_UPDATE_AMOUNT = FIELDIMAGE End Response Function Response PREVIOUS ITEM Message "Press F8 or PF1-Q to cancel the deposit." End Response Function Response PREVIOUS PANEL Message "Press F8 or PF1-Q to cancel the deposit." End Response Output Picture 9,99R9.99 Scale -2 Justification Decimal Use Help Message "Enter the amount of the deposit." Require (AMOUNT > 0) Message "You must specify a non-zero deposit amount." End Field Literal Text Next Line +1 Column 20 Value "Memo" End Literal Field MEMO Same Line Column 30 Function Response NEXT ITEM Message "Press F10 or PF1-E to make the deposit." End Response Display Underlined Output Picture X(35) Use Help Message "Fill in a reminder of where you got the money." End Field End Panel Panel FAREWELL_PANEL Viewport WELCOME_VP /* The FAREWELL_PANEL is displayed when the form is disabled */ Literal Text Line 4 Column 17 Value "Thanks for visiting the" Display Font Size Double Wide End Literal Literal Text Line 7 Column 27 Value " DECforms V3.3" Display Font Size Double High End Literal Literal Text Next Line +2 Column 13 Value "Sample Checking Application" Display Font Size Double High End Literal Literal Text Next Line +2 Column 25 Value "Come again soon." Display Font Size Double Wide End Literal End Panel Panel REGISTER_PANEL Viewport MID_VP Display %Keypad_Application Remove /* The REGISTER_PANEL provides labels, balance, and a section of the * register. Only thirty entries are sent to the form. A different * technique would be used if the program were prepared to deal with an * indefinite length register. */ Exit Response Let NEXT_UPDATE_MESSAGE = "" End Response Function Response TRANSMIT Remove MID_VP Return End Response Function Response QUIT Message "Quitting -- no update made to the register." Return Immediate "EFQUT" Remove MID_VP End Response Use Help Panel REGISTER_PANEL_HELP Apply Field Default Of Same Line Next Column +1 Protected End Default Literal Text Line 1 Column 9 Value "Register - The Account History" Display Font Size Double Wide End Literal Literal Text Line 2 Column 1 Value "Check" Display Bold End Literal Literal Text Line 3 Column 2 Value "Num" Display Bold End Literal Literal Text Same Line Column 6 Value "Date" Display Bold End Literal Literal Text Same Line Column 15 Value "Check Payee or Deposit Memo" Display Bold End Literal Literal Text Same Line Column 52 Value "Chk Amt" Display Bold End Literal Literal Text Same Line Column 61 Value "Dep Amt" Display Bold End Literal Literal Text Same Line Column 70 Value "Balance" Display Bold End Literal Literal Text Line 2 Column 78 Value "Tax" Display Bold End Literal Literal Text Next Line Same Column Value "Ded" Display Bold End Literal Literal Polyline Line 4 Column 1 Line 4 Column 80 End Literal Group REGISTER Vertical Displays 10 First REGISTER_FIRST Scroll By Page /* We've taken over the up and down arrow keys as the UP ITEM * and DOWN ITEM functions. Since the only input fields on this * panel are the register fields, we can let the XX ITEM functions * do the same as XXX OCCURRENCE functions. If anyone a key * which is bound via the default key bindings to the XXX OCCURRENCE * functions, they'll work, too, but get a different message. */ Function Response DOWN ITEM If LAST ITEM Then Message "End of register" Signal Else Position To Down Occurrence End If End Response Function Response UP ITEM If FIRST ITEM Then Message "Beginning of register" Signal Else Position To Up Occurrence End If End Response Function Response NEXT PANEL If LAST ITEM Then Message "End of register" Signal Else Position To Down Occurrence Unseen End If End Response Function Response PREVIOUS PANEL If FIRST ITEM Then Message "Beginning of register" Signal Else Position To Up Occurrence Unseen End If End Response Field REG_CHK_NUM Line 5 Column 1 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture 9999R End Field Field REG_DATE Column 6 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture For Date NN/DD/YY End Field Field REG_MEM Column 15 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture X(35) End Field Field REG_PAY Column 51 Concealed When (REGISTER(**).REG_PAY >= 0) Output Picture 9,999R.99 Scale -2 End Field Field REG_AMOUNT Column 60 Concealed When (REGISTER(**).REG_AMOUNT <= 0) Output Picture 9,999R.99 Scale -2 End Field Field REG_BALANCE Column 69 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture 99,999R.99 Scale -2 End Field Field REG_TAX_DED Column 79 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture 9 Not Protected Range 0 Through 1 End Field End Group Literal Polyline Line 15 Column 1 Line 15 Column 80 End Literal Field REGISTER_FIRST Line 16 Column 2 Output Picture X(50) Output "This is the FIRST register page." When (REGISTER_FIRST = 1) Output "This is the MIDDLE register page." When (REGISTER_FIRST = 11) Output "This is the LAST register page." When (REGISTER_FIRST = 21) Protected End Field Literal Text Next Line Same Column Value "You may change only the tax deduction column, to "- "either 0 or 1." Display Bold End Literal End Panel Panel REVIEW_PANEL Viewport REVIEW_VP Display %Keypad_Application /* REVIEW_PANEL gets the choices for account review */ Exit Response Deactivate Panel REVIEW_PANEL Remove REVIEW_VP Position To Previous Item End Response Function Response QUIT Message "Quitting -- no account review done." Position Immediate To Previous Panel End Response Function Response NEXT PANEL Message "Press F8 or PF1-Q to cancel review choice;" " SELECT or Keypad-period to choose the type of review." End Response Use Help Panel REVIEW_PANEL_HELP Literal Rectangle Line 1 Column 1 Line 5 Column 18 End Literal Literal Text Line 1 Column 2 Value " Review " Display Reverse End Literal Icon CHOICE_REV_REG Function Response SELECT Let OPERATOR_CHOICE = VALUE_REV_REG Return End Response Function Response UP ITEM /* It's on a different panel, so use non-default position */ Position To Previous Item End Response Function Response BOUNDARY CURSOR LEFT /* It's on a different panel, so use non-default position */ Position To Previous Item End Response Active Highlight Reverse Literal Text Line 3 Column 2 Value " Review Register" End Literal End Icon Icon CHOICE_REV_ACCOUNT Function Response SELECT Let OPERATOR_CHOICE = VALUE_REV_ACCOUNT Return End Response Function Response NEXT ITEM /* Null, since there are no more choices on this panel */ End Response Function Response BOUNDARY CURSOR RIGHT /* Null, since there are no more choices on this panel */ End Response Function Response DOWN ITEM /* Null, since there are no more choices on this panel */ End Response Active Highlight Reverse Literal Text Next Line Same Column Value " Review Account " End Literal End Icon End Panel Panel TRANSFER_PANEL Viewport TRANSFER_VP Display %Keypad_Application /* TRANSFER_PANEL gets the choices for transfer between accounts*/ Entry Response Let AMOUNT = 0 Let OPERATOR_CHOICE = 0 End Response Exit Response Remove TRANSFER_VP If IMMEDIATE Then /* From quit */ Deactivate Panel TRANSFER_PANEL Position Immediate To Previous Item End If End Response Function Response QUIT Message "Quitting -- no transfers done." Position Immediate To Previous Panel End Response Function Response PREVIOUS PANEL Message "Quitting -- no transfers done." Position Immediate To Previous Panel End Response Function Response NEXT PANEL Message "Press F8 or PF1-Q to cancel review choice; " " SELECT or Keypad-period to choose the type of review." End Response Use Help Panel TRANSFER_PANEL_HELP Literal Rectangle Line 1 Column 1 Line 7 Column 32 End Literal Literal Text Line 1 Column 2 Value " Transfer Funds " Display Reverse End Literal Literal Text Line 3 Column 2 Value "(" End Literal Field TO_SAVINGS_BUTTON Same Line Next Column Display Character Set Private_Rule Output Picture X(1) Output "`" When (OPERATOR_CHOICE = VALUE_XFER_TO_SAV) Output " " When (OPERATOR_CHOICE <> VALUE_XFER_TO_SAV) Protected End Field Literal Text Same Line Next Column Value ")" End Literal Icon CHOICE_XFER_TO_SAV /* Previous from here means go to main menu */ Function Response SELECT Let OPERATOR_CHOICE = VALUE_XFER_TO_SAV Let NEXT_UPDATE_MESSAGE = "Money transferred from "- "checking to savings" Let MEMO = "*Transfer from checking to savings*" Position Immediate To Field AMOUNT On TRANSFER_PANEL End Response Function Response PREVIOUS ITEM Message "Quitting -- no transfers done." Position Immediate To Previous Panel End Response Function Response UP ITEM Message "Quitting -- no transfers done." Position Immediate To Previous Panel End Response Function Response LEFT ITEM Message "Quitting -- no transfers done." Position Immediate To Previous Panel End Response Active Highlight Reverse Literal Text Same Line Next Column Value " From checking to savings " End Literal End Icon Literal Text Line 4 Column 2 Value "(" End Literal Field TO_CHECKING_BUTTON Same Line Next Column Display Character Set Private_Rule Output Picture X(1) Output "`" When (OPERATOR_CHOICE = VALUE_XFER_TO_CHK) Output " " When (OPERATOR_CHOICE <> VALUE_XFER_TO_CHK) Protected End Field Literal Text Same Line Next Column Value ")" End Literal Icon CHOICE_XFER_TO_CHK Function Response SELECT Let OPERATOR_CHOICE = VALUE_XFER_TO_CHK Let NEXT_UPDATE_MESSAGE = "Money transferred from savings "- "to checking" Let MEMO = "*Transfer from savings to checking*" Position Immediate To Field AMOUNT On TRANSFER_PANEL End Response Function Response NEXT ITEM Message "Press SELECT or Keypad-period to choose one; F8 or "- "PF1-Q to cancel." End Response Function Response DOWN ITEM Message "Press SELECT or Keypad-period to choose one; F8 or "- "PF1-Q to cancel" End Response Function Response BOUNDARY CURSOR RIGHT Message "Press SELECT or Keypad-period to choose one; F8 or "- "PF1-Q to cancel" End Response Function Response PREVIOUS ITEM Position To Previous Item End Response Active Highlight Reverse Literal Text Same Line Next Column Value " From savings to checking " End Literal End Icon Literal Text Next Line +1 Column 5 Value "Amount $" End Literal Field AMOUNT Same Line Next Column +1 Exit Response Let NEXT_UPDATE_AMOUNT = FIELDIMAGE End Response Function Response NEXT ITEM Message "Press F10 or PF1-E to complete" End Response Function Response UP ITEM Let AMOUNT = 0 Let OPERATOR_CHOICE = 0 Position Immediate To Previous Item /*immediate so no validation*/ End Response Validation Response If (OPERATOR_CHOICE = VALUE_XFER_TO_SAV) Then If (AMOUNT > CHECKING_BALANCE) Then Message "Transfer amount must be less than the " "checking account balance." Invalid Signal End If Else If (OPERATOR_CHOICE = VALUE_XFER_TO_CHK) Then If (AMOUNT > SAVINGS_BALANCE) Then Message "Transfer amount must be less than the " "savings account balance." Invalid Signal End If End If End If End Response Output Picture 999,99R9.99 Scale -2 Justification Decimal Use Help Message "Enter the amount to transfer." Protected When (OPERATOR_CHOICE = 0) Require (AMOUNT > 0) Message "Transfer amount must be greater than zero." End Field End Panel Panel WELCOME_PANEL Viewport WELCOME_VP Display %Keypad_Application Remove /* The WELCOME_PANEL is displayed when the form is enabled */ /* We want the form to go on to the next panel for any key * except help. The way to do this is to declare the function * response for help at this level, and then trap everything * else with the BUILTIN, USER, and UNDEFINED function responses. */ Function Response NEXT HELP Enter Help End Response Function Response BUILTIN FUNCTION Return End Response Function Response USER FUNCTION Return End Response Function Response UNDEFINED FUNCTION Return End Response Use Help Panel WELCOME_PANEL_HELP Literal Text Line 2 Column 27 Value " Welcome to the" Display Font Size Double Wide End Literal Literal Text Line 5 Column 27 Value " DECforms V3.3" Display Font Size Double High End Literal Literal Text Next Line +2 Column 13 Value "Sample Checking Application" Display Font Size Double High End Literal Literal Text Next Line +2 Column 27 Value "Your Personal" Display Font Size Double Wide End Literal Literal Text Next Line Column 25 Value "Checking Account" Display Font Size Double Wide End Literal Literal Text Line 16 Column 4 Value "On " End Literal Field VERSION Same Line Next Column Protected End Field Literal Text Next Line Column 4 Value "For user name: " End Literal Field USERNAME Same Line Next Column Protected End Field Literal Rectangle Line 15 Column 48 Line 18 Column 79 End Literal Literal Text Line 16 Column 49 Value "For instructions, press HELP." End Literal Literal Text Next Line Same Column Value "To continue, press RETURN." End Literal End Panel Help Panel ACCOUNT_PANEL_HELP Viewport HELP_VP Display %Keypad_Application /* The remaining panels are help panels, listed alphabetically */ Function Response NEXT HELP Activate Wait on KEYS_HELP Position To Wait On KEYS_HELP End Response Literal Text Value "If you know the password, you can change the data "- "recorded (everything except" End Literal Literal Text Value "the account number and the date the account was "- "opened). If you want to" End Literal Literal Text Value "change any account data, enter the secret password and "- "press TAB or RETURN." End Literal Literal Text Value "If you do not supply the correct password, you won't "- "be able to change" End Literal Literal Text Value "anything." End Literal Literal Text Next Line +1 Value "If the password is accepted, you can change any of the "- "name, address, or" End Literal Literal Text Value "phone fields. When you press F10 (even if you are not "- "in the last field), the" End Literal Literal Text Value 'changes take effect for the rest of the session. '- 'However, these "changes" are' End Literal Literal Text Value "not made permanently in the Sample Application file. "- "This is how the sample" End Literal Literal Text Value "was designed; DECforms does not restrict you from "- "making permanent changes to" End Literal Literal Text Value "any data base. To cancel changes at any time and "- "return to the choice panel," End Literal Literal Text Value "press F8 or PF1-Q." End Literal Literal Text Next Line +1 Value 'HINT: The password is "DECforms"' End Literal Literal Text Next Line Value "Note caps! (Press LF or F13 to retype it)" End Literal Literal Rectangle Line 14 Column 44 Line 17 Column 79 End Literal Literal Text Line 15 Column 45 Value "For more help, press HELP or PF2." End Literal Literal Text Next Line Same Column Value "To resume, PF1-HELP or PF1-PF2." End Literal End Panel Help Panel CASH_PANEL_HELP Viewport HELP_VP Display %Keypad_Application Function Response NEXT HELP Activate Wait on KEYS_HELP Position To Wait On KEYS_HELP End Response Literal Text Line 2 Column 3 Value "The cash choice allows you to pretend you are "- "withdrawing certain amounts" End Literal Literal Text Value "of cash from the checking account. Select an amount "- "from the menu and" End Literal Literal Text Value "press PF1-E or F10. You will see a message telling you "- "that the cash was" End Literal Literal Text Value "withdrawn, and the amount in the balance panel will be "- "updated accordingly." End Literal Literal Text Next Line +1 Value "Unfortunately, DECforms cannot supply you with the "- "actual cash." End Literal Literal Text Value "It is a good product, but it is not quite " End Literal Literal Text Same Line Next Column Value "that" Display Bold End Literal Literal Text Same Line Next Column Value " good!" End Literal Literal Rectangle Line 14 Column 44 Line 17 Column 79 End Literal Literal Text Line 15 Column 45 Value "For more help, press HELP or PF2." End Literal Literal Text Next Line Same Column Value "To resume, PF1-HELP or PF1-PF2." End Literal End Panel Help Panel CHECK_PANEL_HELP Viewport HELP_VP Display %Keypad_Application Function Response NEXT HELP Activate Wait on KEYS_HELP Position To Wait On KEYS_HELP End Response Literal Text Value "You can write checks for amounts up to your current "- "balance, which is" End Literal Literal Text Value "displayed in the balance panel. Fill in the payee, the "- "amount to pay, and, if" End Literal Literal Text Value "you like, what the check is for. Use the RETURN (or "- "TAB) and F12 (BACKSPACE)" End Literal Literal Text Value "keys to move to the next or previous fields. The "- "amount will be accepted if it" End Literal Literal Text Value "is covered by the balance. The payee and memo will "- "always be accepted." End Literal Literal Text Next Line +1 Value "After you are satisfied with the contents of the "- "check, press F10 or PF1-E." End Literal Literal Text Value "The check is recorded in your check register, and the "- "checking balance is" End Literal Literal Text Value "updated. If you enter the check by pressing the PF4 "- "key on the keypad instead" End Literal Literal Text Value "of F10, a copy of the check suitable for printing is "- "written to your SYS$SCRATCH" End Literal Literal Text Value "directory. To cancel the check-writing operation, "- "press F8 or PF1-Q. Any check" End Literal Literal Text Value "partially entered is not recorded in the register." End Literal Literal Rectangle Line 14 Column 44 Line 17 Column 79 End Literal Literal Text Line 15 Column 45 Value "For more help, press HELP or PF2." End Literal Literal Text Value "To resume, PF1-HELP or PF1-PF2." End Literal End Panel Help Panel CHOICE_PANEL_HELP Viewport HELP_VP Display %Keypad_Application Function Response NEXT HELP Activate Wait on KEYS_HELP Position To Wait On KEYS_HELP End Response Literal Text Value "The DECforms Checking Application simulates some "- "functions of electronic" End Literal Literal Text Value "banking. You can make deposits, write checks, make "- "cash withdrawals," End Literal Literal Text Value 'transfer funds, and review account information. Your '- 'account at this "bank"' End Literal Literal Text Value "has already been set up. You have made several "- "deposits, and you have written" End Literal Literal Text Value "some checks. You can choose the following functions by "- "moving the cursor to" End Literal Literal Text Value "your choice with the arrow keys and pressing the "- "SELECT or keypad-period key." End Literal Literal Text Next Line +1 Column 2 Value "Write a check" Display Bold End Literal Literal Text Value "Deposit" Display Bold End Literal Literal Text Value "Cash" Display Bold End Literal Literal Text Value "Transfer" Display Bold End Literal Literal Text Value "Review" Display Bold End Literal Literal Text Value "Exit" Display Bold End Literal Literal Text Same Line -5 Column 18 Value "Displays a check. You type the payee, the amount, and "- "a memo." End Literal Literal Text Same Line +1 Value "Displays a deposit slip. You type the amount and a memo." End Literal Literal Text Same Line +1 Value "Displays a menu. You select an amount of cash to "- "withdraw." End Literal Literal Text Same Line +1 Value "Displays a menu. You transfer between checking and "- "savings." End Literal Literal Text Same Line +1 Value "Displays a menu. You choose check register or account "- "info." End Literal Literal Text Same Line +1 Value "Exits from the Sample Checking Application." End Literal Literal Rectangle Line 14 Column 44 Line 17 Column 79 End Literal Literal Text Line 15 Column 45 Value "For more help, press HELP or PF2." End Literal Literal Text Value "To resume, PF1-HELP or PF1-PF2." End Literal End Panel Help Panel DEPOSIT_PANEL_HELP Viewport HELP_VP Display %Keypad_Application Function Response NEXT HELP Activate Wait on KEYS_HELP Position To Wait On KEYS_HELP End Response Literal Text Line 2 Column 2 Value "To make a deposit, you enter the amount of the deposit "- "and, if you wish," End Literal Literal Text Value "a record of where you got the money." End Literal Literal Text Next Line +1 Value "After entering the amount, press the RETURN key to go "- "to the memo field." End Literal Literal Text Value "Press F12 or Backspace to go back to the amount field. "- "When you are satisfied" End Literal Literal Text Value "with both fields, press F10 or PF1-E to enter the "- "deposit. To cancel the" End Literal Literal Text Value "deposit at any time and return to the choice panel, "- "press F8 or PF1-Q." End Literal Literal Rectangle Line 14 Column 44 Line 17 Column 79 End Literal Literal Text Line 15 Column 45 Value "For more help, press HELP or PF2." End Literal Literal Text Value "To resume, PF1-HELP or PF1-PF2." End Literal End Panel Help Panel KEYS_HELP Viewport HELP_VP Display %Keypad_Application Function Response NEXT HELP Activate Wait on KEYS_MENU_HELP Position To Wait On KEYS_MENU_HELP End Response Literal Text Line 3 Column 2 Value "The keys you use depend on the context you are in: "- "help, menu, or field." End Literal Literal Text Line 5 Column 5 Value "In HELP context (what you are in now), you can use the "- "following keys:" End Literal Literal Text Line 7 Column 7 Value "Prev Screen" End Literal Literal Text Line 7 Column 19 Value "}" End Literal Literal Text Line 7 Column 21 Value "Go to the previous help panel." End Literal Literal Text Line 9 Column 7 Value "Help " End Literal Literal Text Line 9 Column 19 Value "}" End Literal Literal Text Line 9 Column 21 Value "Go to the next help panel." End Literal Literal Text Line 10 Column 7 Value "PF2" End Literal Literal Text Line 10 Column 19 Value "}" End Literal Literal Text Line 12 Column 7 Value "PF1-Help" End Literal Literal Text Line 12 Column 19 Value "}" End Literal Literal Text Line 12 Column 21 Value "Exit help, return to what you were doing." End Literal Literal Text Line 13 Column 7 Value "PF1-PF2" End Literal Literal Text Line 13 Column 19 Value "}" End Literal Literal Rectangle Line 14 Column 44 Line 17 Column 79 End Literal Literal Text Line 15 Column 45 Value "For more help, press HELP or PF2." End Literal Literal Text Value "To resume, PF1-HELP or PF1-PF2." End Literal End Panel Help Panel KEYS_MENU_HELP Viewport HELP_VP Display %Keypad_Application Function Response NEXT HELP Activate Wait on KEYS_FIELD_HELP Position To Wait On KEYS_FIELD_HELP End Response Literal Text Line 1 Column 2 Value "When you are in a menu context, you can use the "- "following keys:" End Literal Literal Text Line 3 Column 4 Value "left arrow" End Literal Literal Text Line 4 Column 4 Value "up arrow" End Literal Literal Text Line 5 Column 4 Value "Backspace" End Literal Literal Text Line 7 Column 4 Value "right arrow }" End Literal Literal Text Line 8 Column 4 Value "down arrow" End Literal Literal Text Line 9 Column 4 Value "Tab" End Literal Literal Text Line 10 Column 4 Value "Return" End Literal Literal Text Line 11 Column 4 Value "Enter" End Literal Literal Text Line 13 Column 4 Value "Select" End Literal Literal Text Line 14 Column 4 Value "Keypad-period" End Literal Literal Text Line 15 Column 4 Value "F10" End Literal Literal Text Line 16 Column 4 Value "PF1-E" End Literal Literal Text Line 13 Column 18 Value "}" End Literal Literal Text Line 14 Column 18 Value "}" End Literal Literal Text Line 15 Column 18 Value "}" End Literal Literal Text Line 16 Column 18 Value "}" End Literal Literal Text Line 3 Column 18 Value "}" End Literal Literal Text Line 4 Column 18 Value "}" End Literal Literal Text Line 4 Column 21 Value "Move to the previous menu item up or to the left." End Literal Literal Text Line 5 Column 18 Value "}" End Literal Literal Text Line 8 Column 18 Value "}" End Literal Literal Text Line 9 Column 18 Value "}" End Literal Literal Text Line 9 Column 21 Value "Move to the next menu item down or to the right." End Literal Literal Text Line 10 Column 18 Value "}" End Literal Literal Text Line 11 Column 18 Value "}" End Literal Literal Text Line 14 Column 21 Value "Select this menu item." End Literal Literal Rectangle Line 14 Column 44 Line 17 Column 79 End Literal Literal Text Line 15 Column 45 Value "For more help, press HELP or PF2." End Literal Literal Text Next Line Same Column Value "To resume, PF1-HELP or PF1-PF2." End Literal End Panel Help Panel KEYS_FIELD_HELP Viewport HELP_VP Display %Keypad_Application Exit Response Message " " /* Clear the message lines */ Message " " End Response Function Response NEXT HELP Message "This is the last help panel. Press PREV SCREEN" " or NEXT SCREEN (PF1-P or PF1-N) to browse through" " all the help panels. Press PF1-HELP or PF1-PF2 to resume." End Response Literal Text Line 1 Column 1 Value " When you are in a field, you can use the following "- "keys:" End Literal Literal Text Line 3 Column 3 Value "left arrow" End Literal Literal Text Line 3 Column 15 Value "}" End Literal Literal Text Line 3 Column 17 Value "Move cursor" End Literal Literal Text Line 3 Column 29 Value "left" End Literal Literal Text Line 3 Column 34 Value "(at left edge of field move to field on left)" End Literal Literal Text Line 4 Column 3 Value "right arrow" End Literal Literal Text Line 4 Column 17 Value "Move cursor right" End Literal Literal Text Line 4 Column 35 Value "(at right edge, move to field on the right)" End Literal Literal Text Line 4 Column 15 Value "}" End Literal Literal Text Line 5 Column 3 Value "up arrow } Move to field above" End Literal Literal Text Line 6 Column 3 Value "down arrow } Move to field below" End Literal Literal Text Line 8 Column 3 Value " "") Then Message NEXT_UPDATE_MESSAGE ": " NEXT_UPDATE_AMOUNT Reset NEXT_UPDATE_MESSAGE End If If (ROOM_IN_REG = 0) Then Message "The register is full, you can only do reviews now." Signal End If End Response Receive Response CHOOSE Display /*Temporary till fix margins bug*/ CHOICE_PANEL Activate Panel CHOICE_PANEL If (OPERATOR_CHOICE = VALUE_DEPOSIT) Then Position To Button CHOICE_DEPOSIT On CHOICE_PANEL End If If (OPERATOR_CHOICE = VALUE_CASH) Then Position To Button CHOICE_CASH On CHOICE_PANEL End If If ((OPERATOR_CHOICE = VALUE_XFER_TO_SAV) OR (OPERATOR_CHOICE = VALUE_XFER_TO_CHK)) Then Position To Button CHOICE_TRANSFER On CHOICE_PANEL End If If ((OPERATOR_CHOICE = VALUE_REV_REG) OR (OPERATOR_CHOICE = VALUE_REV_ACCOUNT)) Then Position To Button CHOICE_REVIEW On CHOICE_PANEL End If End Response Receive Response ACCOUNT Activate Panel ACCOUNT_PANEL End Response Transceive Response REGISTER_RECORD REGISTER_RECORD Activate Field REGISTER(1:ENTRY_COUNT).REG_TAX_DED on REGISTER_PANEL Button OK_BUTTON on REGISTER_PANEL Button CANCEL_BUTTON on REGISTER_PANEL Button GET_HELP_BUTTON on REGISTER_PANEL Position To Field REGISTER(ENTRY_COUNT).REG_TAX_DED On REGISTER_PANEL End Response Function Response TERMINATE HELP Remove HELP_VP Exit Help End Response Function Response PRINT_FUNCTION Message "The print function is not active for this option" Signal End Response Panel ACCOUNT_PANEL Viewport MID_VP Display Viewport Title "Account Information" Display LABEL_ATTR Remove Exit Response Let NEXT_UPDATE_MESSAGE = "" If IMMEDIATE Then /* can happen by "quit" function or focus change to the choice panel */ Message "Quitting -- no update made to personal information." Return Immediate "EFQUT" End If End Response Function Response QUIT Return Immediate "EFQUT" End Response Function Response PREVIOUS PANEL Message "Press the Cancel button or type CTRL/Q to cancel the "- "update." End Response Function Response NEXT PANEL Message "Press the Cancel button or type CTRL/Q to cancel the "- "update or " Message "press the OK button or CTRL/D to update your personal "- "record." End Response Validation Response Validate Panel ACCOUNT_PANEL End Response Use Help Panel ACCOUNT_PANEL_HELP Apply Field Default Of Minimum Length 1 Message "You must enter something for " CURRENTITEM End Default Literal Text Line .170 Column .960 Value "Enter secret password to change the account data:" End Literal Field OP_PASSWORD Line .170 Column 4.560 Entry Response Reset OP_PASSWORD End Response Function Response FOCUS CHANGE /* This function response means you can't go somewhere else via the mouse until this field passes validation. We make an exception for help and cancel. You must either complete the password or cancel. We do this so that we don't have to keep local values for the entries in the panel that are changed before a cancel.*/ If (LOCATORITEM = "CANCEL_BUTTON") Then Position Immediate To Focus Change End If If (LOCATORITEM = "GET_HELP_BUTTON") Then Enter Help Else Position To Focus Change End If End Response Concealed Input Picture X(12) Use Help Message "Enter the secret word to change the account data." " (Hint: try Help again.)" Require (OP_PASSWORD = PASSWORD) Message "You must enter the right password to change the data. " "Hint: press the HELP button." End Field Literal Rectangle Line .519 Column .077 Line 3.400 Column 6.530 End Literal Literal Text Line .730 Column 3.780 Value "Account Number " End Literal Field ACCOUNT_NUMBER Line .730 Column 5.140 Display Border Width Is .000 NoShadow LABEL_ATTR Output Picture 9(5) Protected End Field Literal Text Line .960 Column 3.780 Value "Opened" End Literal Field DATE_ESTABLISHED Line .960 Column 5.140 Display Border Width Is .000 NoShadow LABEL_ATTR Output Picture For Date NN/DD/YYYY Protected End Field Literal Text Line .727 Column .285 Value "NAME" End Literal Literal Text Line .974 Column .467 Value "Last" End Literal Field LAST_NAME Line .974 Column .974 Output Picture X(20) End Field Literal Text Line 1.286 Column .467 Value "First" End Literal Field FIRST_NAME Line 1.286 Column .974 Output Picture X(15) End Field Literal Text Line 1.598 Column .467 Value "Middle" End Literal Field MIDDLE_NAME Line 1.598 Column .974 Output Picture X(15) No Minimum Length End Field Literal Text Line 2.052 Column .285 Value "ADDRESS" End Literal Literal Text Line 2.286 Column .467 Value "Street" End Literal Field STREET Line 2.286 Column .974 Output Picture X(30) End Field Literal Text Line 2.585 Column .467 Value "City" End Literal Field CITY Line 2.585 Column .974 Output Picture X(20) End Field Literal Text Line 2.884 Column .467 Value "State" End Literal Field STATE Line 2.884 Column .974 Width .400 Output Picture X(2) Uppercase Minimum Length 2 Message "State field must be two letters" Search STATE_LIST Message "Must be one of the fifty U.S.A. states or DC." End Field Literal Text Line 2.884 Column 1.830 Value "Zip" End Literal Field ZIP_CODE Line 2.884 Column 2.200 Output Picture 9(5) Require (ZIP_CODE >= 100) Message "Zip code region must be at least 1; " "that means the zip code must be 100 or more." End Field Literal Text Line 2.052 Column 3.819 Value "PHONE" End Literal Literal Text Line 2.286 Column 4.079 Value "Home" End Literal Field HOME_PHONE Line 2.286 Column 4.729 Output Picture '('999')'999'-'9999 Minimum Length 10 Message "You must supply home phone number, " "including area code." End Field Literal Text Line 2.585 Column 4.079 Value "Business" End Literal Field WORK_PHONE Line 2.585 Column 4.729 Output Picture '('999')'999'-'9999 No Minimum Length Range 0 Through 0 1000000000 Through 9999999999 Message "Business phone must be null or all 10 digits" End Field Push Button OK_BUTTON Line 3.494 Column .779 Height .450 Width 1.500 Function Response TRIGGER OBJECT Return End Response Display BUTTON_LABEL_ATTR Label "OK" End Button Push Button CANCEL_BUTTON Line 3.494 Column 2.520 Height .450 Width 1.500 Function Response TRIGGER OBJECT Return Immediate "EFQUT" End Response Display BUTTON_LABEL_ATTR Label "Cancel" End Button Push Button GET_HELP_BUTTON Line 3.494 Column 4.274 Height .450 Width 1.500 Function Response TRIGGER OBJECT Enter Help End Response Function Response NEXT ITEM Position To Field LAST_NAME On ACCOUNT_PANEL End Response Display BUTTON_LABEL_ATTR Label "Help" End Button End Panel Panel CASH_PANEL Viewport CASH_VP Display Viewport Title "Cash Withdrawal" Display LABEL_ATTR Remove No Scrollbars Entry Response Reset MEMO AMOUNT End Response Exit Response Deactivate Panel CASH_PANEL If (AMOUNT = 0) Then /*if amount is zero on exit, operator made no choice*/ Message "Quitting -- no cash withdrawn." /*Leaving because operator made a choice*/ Else Let OPERATOR_CHOICE = VALUE_CASH Let MEMO = "*Cash withdrawal*" Let NEXT_UPDATE_MESSAGE = "Cash withdrawal made against "- "your checking account" End If End Response Function Response QUIT /*Causes exit & eventual deactivate of this panel*/ Position Immediate To Button CHOICE_CASH On CHOICE_PANEL End Response Function Response NEXT ITEM If ( NOT PANEL LAST ITEM) Then Position To Next Item End If End Response Function Response UP ITEM If UPPERMOST ITEM Then Position Immediate To Button CHOICE_CASH On CHOICE_PANEL /*causes us to go to previous panel*/ Else Position To Up Item End If End Response Use Help Panel CASH_PANEL_HELP Push Button CHOICE_CASH_10 Line .000 Column .000 Height .270 Width 1.150 Function Response TRIGGER OBJECT Let AMOUNT = 1000 Let NEXT_UPDATE_AMOUNT = "$10" Return End Response Active Highlight Reverse Display MENU_BUTTON_LABEL_ATTR Protected When (CHECKING_BALANCE < 1000) Label " $10" End Button Push Button CHOICE_CASH_20 Line .280 Column .000 Height .270 Width 1.150 Function Response TRIGGER OBJECT Let AMOUNT = 2000 Let NEXT_UPDATE_AMOUNT = "$20" Return End Response Active Highlight Reverse Display MENU_BUTTON_LABEL_ATTR Protected When (CHECKING_BALANCE < 2000) Label " $20" End Button Push Button CHOICE_CASH_50 Line .580 Column .000 Height .270 Width 1.150 Function Response TRIGGER OBJECT Let AMOUNT = 5000 Let NEXT_UPDATE_AMOUNT = "$50" Return End Response Active Highlight Reverse Display MENU_BUTTON_LABEL_ATTR Protected When (CHECKING_BALANCE < 5000) Label " $50" End Button Push Button CHOICE_CASH_100 Line .860 Column .000 Height .270 Width 1.150 Function Response TRIGGER OBJECT Let AMOUNT = 10000 Let NEXT_UPDATE_AMOUNT = "$100" Return End Response Active Highlight Reverse Display MENU_BUTTON_LABEL_ATTR Protected When (CHECKING_BALANCE < 10000) Label "$100" End Button Push Button CANCEL_BUTTON Line 1.140 Column .000 Height .270 Width 1.150 Function Response TRIGGER OBJECT Position Immediate To Button CHOICE_CASH On CHOICE_PANEL End Response Active Highlight Reverse Display MENU_BUTTON_LABEL_ATTR Label "Cancel" End Button End Panel Panel CHECK_PANEL Viewport MID_VP Display Viewport Title "Write A Check" Display LABEL_ATTR Remove Entry Response Reset MEMO AMOUNT CHECK_MEMO End Response Exit Response /* There two reasons we could be leaving the panel. QUIT : The operator pressed the QUIT key or did FOCUS CHANGE to menu on choice_panel. In either case, there was a POSITION IMMEDIATE. We remove and deactivate the panel and tell operator that no check was written. TRANSMIT : We're done. In this case, we make some assignments for the record being sent back and for the action the next time the update record comes in. We get rid of the viewport, but keep the panel active, so that the validation on the fields occurs. */ If IMMEDIATE Then Message "Quitting -- no check written." Deactivate /*Leaving because operator made a choice*/ Panel CHECK_PANEL Else Let OPERATOR_CHOICE = VALUE_CHECK Let NEXT_UPDATE_MESSAGE = "Check Paid" End If End Response Function Response QUIT Position Immediate To Button CHOICE_CHECK On CHOICE_PANEL End Response Function Response PRINT_FUNCTION Validate Panel CHECK_PANEL If ( NOT IMMEDIATE) Then /* print and return only if the check is okay */ Print CHECK_PANEL Message "The check has been printed to a file " Return End If End Response Function Response NEXT PANEL Message "Press the OK button to finish the check." End Response Function Response PREVIOUS PANEL Message "Press the Cancel button to cancel the check." End Response Validation Response Validate Panel CHECK_PANEL End Response Use Help Panel CHECK_PANEL_HELP Literal Rectangle Line .441 Column .129 Line 3.691 Column 7.014 End Literal Field CHECK_NUMBER Line .584 Column 5.859 Display Border Width Is .000 NoShadow LABEL_ATTR Output Picture 9999R9 Protected End Field Field MAIL_NAME Line .584 Column .311 Display Border Width Is .000 LABEL_ATTR NoShadow Protected End Field Field STREET Line .844 Column .311 Display Border Width Is .000 LABEL_ATTR NoShadow Protected End Field Field MAIL_CSZ Line 1.091 Column .311 Display Border Width Is .000 LABEL_ATTR NoShadow Protected End Field Field HOME_PHONE Line 1.338 Column .311 Display Border Width Is .000 NoShadow LABEL_ATTR Output Picture 'Home ('999')'999'-'9999 Protected End Field Field WORK_PHONE Line 1.338 Column 2.416 Concealed When (WORK_PHONE = 0) Display Border Width Is .000 NoShadow LABEL_ATTR Output Picture 'Office ('999')'999'-'9999 Protected End Field Literal Text Line 1.598 Column 4.742 Value "Date:" End Literal Field CURRENT_DATE Line 1.598 Column 5.209 Display Border Width Is .000 NoShadow LABEL_ATTR Output Picture For Date MMMMMMMMMQ' 'DDQ', 'YYYY Protected End Field Literal Text Line 2.091 Column .428 Value "Pay to" End Literal Field MEMO Line 2.065 Column .974 Function Response PREVIOUS ITEM Message "Press the Cancel button or type CTRL/Q to cancel the "- "check." End Response Output Picture X(35) Use Help Message "Enter the person or organization to whom you" " wish to pay the check." Minimum Length 1 Message "You must fill in the payee." End Field Literal Text Line 2.091 Column 4.742 Value "Amount $" End Literal Field AMOUNT Line 2.091 Column 5.625 Exit Response Let NEXT_UPDATE_AMOUNT = FIELDIMAGE End Response Output Picture 999,99R9.99 Scale -2 Replace Leading "*" Use Help Message "Enter the amount to be paid." Range 0 Through CHECKING_BALANCE Message "Check amount must be less than the checking "- "account balance." Require (AMOUNT > 0) Message "Check amount must be greater than zero." End Field Literal Text Line 2.585 Column .428 Value "Memo" End Literal Field CHECK_MEMO Line 2.585 Column .974 Function Response NEXT ITEM Message "Press the Ok button or CTRL/D to finish the check." End Response Output Picture X(35) Use Help Message "Fill in a reminder to yourself about what the" " check is for. You need not fill this in." End Field Literal Text Line 3.338 Column .428 Value "FIRST NATIONAL BANK" Display Font Weight Bold End Literal Literal Text Line 3.338 Column 4.742 Value "Account" End Literal Field ACCOUNT_NUMBER Line 3.338 Column 5.625 Display Border Width Is .000 NoShadow LABEL_ATTR Output Picture 9(5) Protected End Field Push Button OK_BUTTON Line 4.092 Column .909 Height .450 Width 1.500 Function Response TRIGGER OBJECT Return End Response Display BUTTON_LABEL_ATTR Label "OK" End Button Push Button CANCEL_BUTTON Line 4.092 Column 2.650 Height .450 Width 1.500 Function Response TRIGGER OBJECT Position Immediate To Button CHOICE_CHECK On CHOICE_PANEL End Response Display BUTTON_LABEL_ATTR Label "Cancel" End Button Push Button GET_HELP_BUTTON Line 4.092 Column 4.404 Height .450 Width 1.500 Function Response TRIGGER OBJECT Enter Help End Response Display BUTTON_LABEL_ATTR Label "Help" End Button End Panel Panel CHOICE_PANEL Viewport TOP_VP Display Viewport IconLabel "Checking Demo" Title "DECforms Demo: Your Checking Account" Display LABEL_ATTR Function Response NEXT ITEM If LAST ITEM Then Position To First Item Else Position To Next Item End If End Response Function Response PREVIOUS ITEM If FIRST ITEM Then Position To Last Item Else Position To Previous Item End If End Response Function Response QUIT Position Immediate To Button CHOICE_EXIT On CHOICE_PANEL Message "Press Exit button or type Ctrl/Q to leave the application." End Response Function Response TRANSMIT /*Means nothing at this point*/ End Response Use Help Panel CHOICE_PANEL_HELP Push Button CHOICE_CHECK Line .000 Column .012 Height .300 Width 1.200 Function Response TRIGGER OBJECT If (CHECKING_BALANCE = 0) Then Message "You can't write a check; you have a zero balance." Invalid Else Activate Panel CHECK_PANEL Position Immediate To Panel CHECK_PANEL End If End Response Display MENU_BUTTON_LABEL_ATTR Protected When (ROOM_IN_REG = 0) Label " Write a check... " End Button Push Button CHOICE_DEPOSIT Line .000 Column 1.338 Height .300 Width 1.000 Function Response TRIGGER OBJECT Activate Panel DEPOSIT_PANEL Position Immediate To Panel DEPOSIT_PANEL End Response Display MENU_BUTTON_LABEL_ATTR Protected When (ROOM_IN_REG = 0) Label " Deposit... " End Button Push Button CHOICE_CASH Line .000 Column 2.350 Height .300 Width .750 Function Response TRIGGER OBJECT If (CHECKING_BALANCE < 1000) Then Message "You can't withdraw cash because your checking" " account balance is too small." Signal Else Display /*Temporary till fix margins bug*/ CASH_PANEL Activate Panel CASH_PANEL Position Immediate To Panel CASH_PANEL End If End Response Display MENU_BUTTON_LABEL_ATTR Protected When (ROOM_IN_REG = 0) Label " Cash... " End Button Push Button CHOICE_TRANSFER Line .000 Column 3.200 Height .300 Width 1.000 Function Response TRIGGER OBJECT Display /*Temporary till fix margins bug*/ TRANSFER_PANEL Activate Panel TRANSFER_PANEL Position Immediate To Panel TRANSFER_PANEL End Response Display MENU_BUTTON_LABEL_ATTR Protected When (ROOM_IN_REG = 0) Label " Transfer... " End Button Push Button CHOICE_REVIEW Line .000 Column 4.300 Height .300 Width 1.000 Function Response TRIGGER OBJECT Display /*Temporary till fix margins bug*/ REVIEW_PANEL Activate Panel REVIEW_PANEL Position Immediate To Panel REVIEW_PANEL End Response Display MENU_BUTTON_LABEL_ATTR Label " Review... " End Button Push Button CHOICE_EXIT Line .000 Column 5.400 Height .300 Width .500 Function Response TRIGGER OBJECT Let OPERATOR_CHOICE = VALUE_EXIT Return End Response Function Response QUIT Let OPERATOR_CHOICE = VALUE_EXIT Return End Response Display MENU_BUTTON_LABEL_ATTR Label " Exit " End Button Push Button GET_HELP_BUTTON Line .000 Column 7.700 Height .300 Width .666 Function Response TRIGGER OBJECT Enter Help End Response Display MENU_BUTTON_LABEL_ATTR Label "Help" End Button Literal Polyline Line .300 Column .000 Line .300 Column 9.800 End Literal Literal Text Line 6.600 Column 6.600 Value "Balances:" End Literal Literal Text Line 6.600 Column 7.300 Value "Checking:" End Literal Field CHECKING_BALANCE Line 6.600 Column 8.000 Display Border Width Is .000 NoShadow LABEL_ATTR Output Picture 99,999,99W9.99 Scale -2 Protected End Field Literal Text Line 6.850 Column 7.300 Value "Savings: " End Literal Field SAVINGS_BALANCE Line 6.850 Column 8.000 Display Border Width Is .000 NoShadow LABEL_ATTR Output Picture 99,999,99W9.99 Scale -2 Protected End Field End Panel Panel DEPOSIT_PANEL Viewport MID_VP Display Viewport Title "Deposit Record" Display LABEL_ATTR Remove Entry Response Reset MEMO AMOUNT End Response Exit Response /* See the check panel for an explanation of this response */ If IMMEDIATE Then /*Note: could also ask if amount=0 */ Message "Quitting -- no deposit made." Deactivate Panel DEPOSIT_PANEL Else Let OPERATOR_CHOICE = VALUE_DEPOSIT Let NEXT_UPDATE_MESSAGE = "Deposit credited to your "- "checking account" End If End Response Function Response QUIT Position Immediate To Button CHOICE_DEPOSIT On CHOICE_PANEL End Response Function Response PRINT_FUNCTION Validate Panel DEPOSIT_PANEL If ( NOT IMMEDIATE) Then /* print only if the deposit is okay */ Print DEPOSIT_PANEL Message "The deposit slip has been printed to a file " Return End If End Response Function Response NEXT PANEL Message "Press the OK button or type CTRL/D to make the deposit." End Response Function Response PREVIOUS PANEL Message "Press the Cancel button or type CTRL/Q to cancel the "- "deposit." End Response Validation Response Validate Panel DEPOSIT_PANEL End Response Use Help Panel DEPOSIT_PANEL_HELP Literal Rectangle Line .363 Column .155 Line 2.727 Column 5.741 End Literal Literal Text Line .506 Column .558 Value "Date:" End Literal Field CURRENT_DATE Line .506 Column 1.221 Display Border Width Is .000 NoShadow LABEL_ATTR Output Picture For Date MMMMMMMMMQ' 'DDQ', 'YYYY Protected End Field Literal Text Line .506 Column 3.793 Value "Account" End Literal Field ACCOUNT_NUMBER Line .506 Column 4.677 Display Border Width Is .000 NoShadow LABEL_ATTR Output Picture 9(5) Protected End Field Literal Text Line 1.260 Column .857 Value "Deposit $" End Literal Field AMOUNT Line 1.260 Column 1.974 Exit Response Let NEXT_UPDATE_AMOUNT = FIELDIMAGE End Response Function Response PREVIOUS ITEM Message "Press the Cancel button or type CTRL/Q to cancel the "- "deposit." End Response Output Picture 9,99R9.99 Scale -2 Use Help Message "Enter the amount of the deposit." Require (AMOUNT > 0) Message "You must specify a non-zero deposit amount." End Field Literal Text Line 1.766 Column .857 Value "Memo" End Literal Field MEMO Line 1.766 Column 1.974 Function Response NEXT ITEM Message "Press the OK button or type CTRL/D to make the "- "deposit." End Response Output Picture X(35) Use Help Message "Fill in a reminder of where you got the money." End Field Push Button OK_BUTTON Line 3.053 Column .441 Height .450 Width 1.500 Function Response TRIGGER OBJECT Return End Response Display BUTTON_LABEL_ATTR Label "OK" End Button Push Button CANCEL_BUTTON Line 3.053 Column 2.182 Height .450 Width 1.500 Function Response TRIGGER OBJECT Position Immediate To Button CHOICE_DEPOSIT On CHOICE_PANEL End Response Display BUTTON_LABEL_ATTR Label "Cancel" End Button Push Button GET_HELP_BUTTON Line 3.053 Column 3.936 Height .450 Width 1.500 Function Response TRIGGER OBJECT Enter Help End Response Display BUTTON_LABEL_ATTR Label "Help" End Button End Panel Panel REGISTER_PANEL Viewport REGISTER_VP Display Viewport Title "Register: Deposits and Withdrawals" Display Border Width Is .000 NoShadow LABEL_ATTR Remove Exit Response Let NEXT_UPDATE_MESSAGE = "" If IMMEDIATE Then Message "Quitting -- no update made to the register." Return Immediate "EFQUT" End If End Response Function Response QUIT Return Immediate "EFQUT" End Response Validation Response Validate Panel REGISTER_PANEL End Response Use Help Panel REGISTER_PANEL_HELP Apply Field Default Of Protected End Default Literal Text Line .200 Column .111 Value "Check" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column .111 Value "Num" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column .666 Value "Date" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column 1.665 Value "Check Payee or Deposit Memo" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column 5.522 Value "Chk Amt" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column 6.521 Value "Dep Amt" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column 7.520 Value "Balance" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .200 Column 8.408 Value "Tax" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column 8.408 Value "Ded" Display Font Weight Bold LABEL_ATTR End Literal Group REGISTER Vertical Displays 10 First REGISTER_FIRST Scroll By Page Line .700 Column .111 Height .320 Function Response DOWN ITEM If LAST OCCURRENCE VERTICAL Then Message "End of register" Signal Else Position To Down Occurrence End If End Response Function Response UP ITEM If FIRST OCCURRENCE VERTICAL Then Message "Beginning of register" Signal Else Position To Up Occurrence End If End Response Function Response NEXT PANEL If LAST OCCURRENCE VERTICAL Then Message "End of register" Signal Else Position To Down Occurrence Unseen End If End Response Function Response PREVIOUS PANEL If FIRST OCCURRENCE VERTICAL Then Message "Beginning of register" Signal Else Position To Up Occurrence Unseen End If End Response Field REG_CHK_NUM Line .000 Column .000 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture 9999R End Field Field REG_DATE Line .000 Column .555 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture For Date NN/DD/YY End Field Field REG_MEM Line .000 Column 1.554 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture X(35) End Field Field REG_PAY Line .000 Column 5.272 Concealed When (REGISTER(**).REG_PAY >= 0) Output Picture 9,999R.99 Scale -2 End Field Field REG_AMOUNT Line .000 Column 6.271 Concealed When (REGISTER(**).REG_AMOUNT <= 0) Output Picture 9,999R.99 Scale -2 End Field Field REG_BALANCE Line .000 Column 7.120 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture 99,999R.99 Scale -2 End Field Field REG_TAX_DED Line .000 Column 8.408 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture 9 Not Protected Range 0 Through 1 End Field Literal Polyline Line .300 Column .100 Line .300 Column 8.500 End Literal End Group Literal Text Line 4.000 Column .222 Value "You may change only the tax deduction column, to 0 or 1." Display Font Weight Bold LABEL_ATTR End Literal Push Button OK_BUTTON Line 4.350 Column 2.119 Height .450 Width 1.500 Apply No Field Default Function Response TRIGGER OBJECT Return End Response Display BUTTON_LABEL_ATTR Label "OK" End Button Push Button CANCEL_BUTTON Line 4.350 Column 3.869 Height .450 Width 1.500 Apply No Field Default Function Response TRIGGER OBJECT Return Immediate "EFQUT" End Response Display BUTTON_LABEL_ATTR Label "Cancel" End Button Push Button GET_HELP_BUTTON Line 4.350 Column 5.619 Height .450 Width 1.500 Apply No Field Default Function Response TRIGGER OBJECT Enter Help End Response Display BUTTON_LABEL_ATTR Label "Help" End Button End Panel Panel REVIEW_PANEL Viewport REVIEW_VP Display Viewport Title "Review Account or Register" Display LABEL_ATTR Remove No Scrollbars Exit Response Deactivate Panel REVIEW_PANEL End Response Function Response QUIT Position Immediate To Button CHOICE_REVIEW On CHOICE_PANEL End Response Function Response NEXT PANEL Message "Press the Cancel button or CTRL/Q to cancel review menu;" " Select with the mouse or Return key to choose the type "- "of review." End Response Use Help Panel REVIEW_PANEL_HELP Push Button CHOICE_REV_REG Line .000 Column .000 Height .270 Width 1.500 Function Response TRIGGER OBJECT Let OPERATOR_CHOICE = VALUE_REV_REG Return End Response Function Response UP ITEM Position To Previous Item End Response Active Highlight Reverse Display MENU_BUTTON_LABEL_ATTR Label "Review Register" End Button Push Button CHOICE_REV_ACCOUNT Line .280 Column .000 Height .270 Width 1.500 Function Response TRIGGER OBJECT Let OPERATOR_CHOICE = VALUE_REV_ACCOUNT Return End Response Active Highlight Reverse Display MENU_BUTTON_LABEL_ATTR Label "Review Account" End Button Push Button CANCEL_BUTTON Line .560 Column .000 Height .270 Width 1.500 Function Response TRIGGER OBJECT Position Immediate To Button CHOICE_REVIEW On CHOICE_PANEL End Response Function Response NEXT ITEM /* Null, since there are no more choices on this panel */ End Response Function Response DOWN ITEM /* Null, since there are no more choices on this panel */ End Response Active Highlight Reverse Display MENU_BUTTON_LABEL_ATTR Label "Cancel " End Button End Panel Panel TRANSFER_PANEL Viewport TRANSFER_VP Display Viewport Title "Transfer Funds" Display LABEL_ATTR Remove Entry Response Let AMOUNT = 0 Let OPERATOR_CHOICE = 0 End Response Exit Response If IMMEDIATE Then /* From quit or focus change */ Message "Quitting -- no transfers done." Deactivate Panel TRANSFER_PANEL End If End Response Function Response QUIT Position Immediate To Button CHOICE_TRANSFER On CHOICE_PANEL End Response Function Response PREVIOUS PANEL Position Immediate To Button CHOICE_TRANSFER On CHOICE_PANEL End Response Function Response NEXT PANEL Message "Press the Cancel button or type CTRL/D to cancel transfer." End Response Function Response LEFT ITEM End Response Function Response RIGHT ITEM End Response Validation Response If (OPERATOR_CHOICE = 0) Then Invalid Position Immediate To Button CHOICE_XFER_TO_SAV On TRANSFER_PANEL Message "You must specify a direction and an amount or you "- "must cancel." Else Validate Field AMOUNT on TRANSFER_PANEL End If End Response Use Help Panel TRANSFER_PANEL_HELP Field TO_SAVINGS_BUTTON Line .150 Column .250 Width .250 Display NoShadow Border Width Is .020 Output Picture X(1) Output "X" When (OPERATOR_CHOICE = VALUE_XFER_TO_SAV) Output " " When (OPERATOR_CHOICE <> VALUE_XFER_TO_SAV) Protected End Field Push Button CHOICE_XFER_TO_SAV Line .150 Column .750 Height .350 Function Response TRIGGER OBJECT Let OPERATOR_CHOICE = VALUE_XFER_TO_SAV Let NEXT_UPDATE_MESSAGE = "Money transferred from "- "checking to savings" Let MEMO = "*Transfer from checking to savings*" Position Immediate To Field AMOUNT On TRANSFER_PANEL End Response Function Response PREVIOUS ITEM Position Immediate To Button CHOICE_TRANSFER On CHOICE_PANEL End Response Function Response UP ITEM Position Immediate To Button CHOICE_TRANSFER On CHOICE_PANEL End Response Display MENU_BUTTON_LABEL_ATTR Label "From checking to savings" End Button Field TO_CHECKING_BUTTON Line .608 Column .250 Width .250 Display NoShadow Border Width Is .020 Output Picture X(1) Output "X" When (OPERATOR_CHOICE = VALUE_XFER_TO_CHK) Output " " When (OPERATOR_CHOICE <> VALUE_XFER_TO_CHK) Protected End Field Push Button CHOICE_XFER_TO_CHK Line .608 Column .750 Height .350 Width 2.000 Function Response TRIGGER OBJECT Let OPERATOR_CHOICE = VALUE_XFER_TO_CHK Let NEXT_UPDATE_MESSAGE = "Money transferred from savings "- "to checking" Let MEMO = "*Transfer from savings to checking*" Position Immediate To Field AMOUNT On TRANSFER_PANEL End Response Function Response NEXT ITEM Message "Type Select or Return or mouse click to choose one." Message "Press the Cancel button to cancel." End Response Function Response DOWN ITEM Message "Type Select or Return or mouse click to choose one." Message "Press the Cancel button to cancel." End Response Function Response PREVIOUS ITEM Position To Previous Item End Response Display MENU_BUTTON_LABEL_ATTR Label "From savings to checking" End Button Literal Text Line 1.150 Column .500 Value "Amount $" End Literal Field AMOUNT Line 1.150 Column 1.500 Exit Response Let NEXT_UPDATE_AMOUNT = FIELDIMAGE End Response Function Response UP ITEM Let AMOUNT = 0 Let OPERATOR_CHOICE = 0 Position Immediate To Previous Item End Response Validation Response If (OPERATOR_CHOICE = VALUE_XFER_TO_SAV) Then If (AMOUNT > CHECKING_BALANCE) Then Message "Transfer amount must be less than the " "checking account balance." Invalid Signal End If Else If (OPERATOR_CHOICE = VALUE_XFER_TO_CHK) Then If (AMOUNT > SAVINGS_BALANCE) Then Message "Transfer amount must be less than the " "savings account balance." Invalid Signal End If End If End If If IMMEDIATE Then Position Immediate To Field AMOUNT On TRANSFER_PANEL End If End Response Output Picture 999,99R9.99 Scale -2 Use Help Message "Enter the amount to transfer." Protected When (OPERATOR_CHOICE = 0) Require (AMOUNT > 0) Message "Transfer amount must be greater than zero." End Field Push Button OK_BUTTON Line 1.673 Column .410 Height .450 Width .750 Function Response TRIGGER OBJECT Return End Response Display BUTTON_LABEL_ATTR Label "OK" End Button Push Button CANCEL_BUTTON Line 1.673 Column 1.540 Height .450 Width .750 Function Response TRIGGER OBJECT Position Immediate To Button CHOICE_TRANSFER On CHOICE_PANEL End Response Display BUTTON_LABEL_ATTR Label "Cancel" End Button Push Button GET_HELP_BUTTON Line 1.673 Column 2.660 Height .450 Width .750 Function Response TRIGGER OBJECT Enter Help End Response Display BUTTON_LABEL_ATTR Label "Help" End Button End Panel Panel WELCOME_PANEL Viewport TOP_VP Display LABEL_ATTR Remove Function Response NEXT HELP Enter Help End Response Use Help Panel WELCOME_PANEL_HELP Literal Text Line .500 Column 2.997 Value "Welcome to the" Display Font Size 18 End Literal Literal Text Line 1.000 Column 2.988 Value "DECforms V3.3" Display Font Size 18 Font Weight Bold End Literal Literal Text Line 1.507 Column 1.987 Value "Sample Checking Application" Display Font Size 24 End Literal Literal Text Line 2.182 Column 3.118 Value "Your Personal" Display Font Size 18 End Literal Literal Text Line 2.572 Column 2.910 Value "Checking Account" Display Font Size 18 End Literal Literal Text Line 4.000 Column .444 Value "On " End Literal Field VERSION Line 4.000 Column .777 Display Border Width Is .000 LABEL_ATTR NoShadow Protected End Field Literal Text Line 4.250 Column .444 Value "For user name: " End Literal Field USERNAME Line 4.250 Column 1.887 Display Border Width Is .000 LABEL_ATTR NoShadow Protected End Field Push Button CONTINUE_BUTTON Line 3.884 Column 4.079 Height .550 Width 1.500 Function Response TRIGGER OBJECT Return End Response Display BUTTON_LABEL_ATTR Label "Continue" End Button Push Button GET_HELP_BUTTON Line 3.871 Column 5.833 Height .550 Width 1.500 Function Response TRIGGER OBJECT Enter Help End Response Display BUTTON_LABEL_ATTR Label "Help" End Button End Panel Help Panel ACCOUNT_PANEL_HELP Viewport HELP_VP Display Viewport Title "Account Information Help" Display LABEL_ATTR Remove Literal Text Line .250 Column .111 Value "If you know the password, you can change the data "- "recorded (everything except the" End Literal Literal Text Line .500 Column .111 Value "account number and the date the account was opened). "- "If you want to change any" End Literal Literal Text Line .750 Column .111 Value "account data, enter the secret password and press the "- "Tab key." End Literal Literal Text Line 1.250 Column .111 Value "If the password is accepted, you can change any of the "- "name, address, or phone fields." End Literal Literal Text Line 1.500 Column .111 Value "When you press the OK button or type Ctrl/D, the "- "changes take effect for the rest of the session." End Literal Literal Text Line 1.750 Column .111 Value "However, these changes are not made permanently in the "- "Sample Application file. This " End Literal Literal Text Line 2.000 Column .111 Value "is how the sample was designed; DECforms does not "- "restrict you from making permanent " End Literal Literal Text Line 2.250 Column .111 Value "changes to any data base. To cancel changes at any "- "time and return to the choice panel, " End Literal Literal Text Line 2.500 Column .111 Value "press the Cancel button or type Ctrl/Q." End Literal Literal Text Line 3.000 Column .111 Value 'HINT: The password is "DECforms"' End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel CASH_PANEL_HELP Viewport HELP_VP Display Viewport Title "Cash Withdrawal Help" Display LABEL_ATTR Remove Literal Text Line .500 Column .333 Value "The cash choice allows you to pretend you are "- "withdrawing certain amounts of cash from" End Literal Literal Text Line .750 Column .333 Value "the checking account. Select an amount from the menu. "- "You will see a message telling" End Literal Literal Text Line 1.000 Column .333 Value "you that the cash was withdrawn and the amount in the "- "balance panel will be updated" End Literal Literal Text Line 1.250 Column .333 Value "accordingly. Select Cancel or type Ctrl/Q to return to "- "the main menu." End Literal Literal Text Line 2.000 Column .333 Value "Unfortunately, DECforms cannot supply you with the "- "actual cash. It is a good " End Literal Literal Text Line 2.250 Column .333 Value "product but it is not quite" End Literal Literal Text Line 2.255 Column 2.050 Value "that" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 2.250 Column 2.400 Value "good!" End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel CHECK_PANEL_HELP Viewport HELP_VP Display Viewport Title "Write A Check Help" Display LABEL_ATTR Remove Literal Text Line .250 Column .222 Value "You can write checks for amounts up to your current "- "balance, which is displayed in the" End Literal Literal Text Line .500 Column .222 Value "main panel. Fill in the payee, the amount to pay and "- "if you like, what the check is for." End Literal Literal Text Line .750 Column .222 Value "The amount will be accepted if it is covered by the "- "balance. The payee and memo will" End Literal Literal Text Line 1.000 Column .222 Value "always be accepted. After you are satisfied with the "- "contents of the check, press the" End Literal Literal Text Line 1.250 Column .222 Value "OK button or type Ctrl/D." End Literal Literal Text Line 1.750 Column .222 Value "The check is recorded in your check register, and the "- "checking balance is updated. To" End Literal Literal Text Line 2.000 Column .222 Value "print a copy of the check press Ctrl/P on the "- "keyboard. To cancel the check-writing" End Literal Literal Text Line 2.250 Column .222 Value "operation, press the Cancel button or type Ctrl/Q." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel CHOICE_PANEL_HELP Viewport HELP_VP Display Viewport Title "Personal Checking Account Help" Display LABEL_ATTR Remove Literal Text Line .250 Column .111 Value "The DECforms Checking Application simulates some "- "functions of electronic banking. " End Literal Literal Text Line .500 Column .111 Value "You can make deposits, write checks, make cash "- "withdrawals, transfer " End Literal Literal Text Line .750 Column .111 Value 'funds, and review account information. Your account at '- 'this "bank" has already ' End Literal Literal Text Line 1.000 Column .111 Value "been set up. You have made several deposits, and you "- "have written some checks. " End Literal Literal Text Line 1.250 Column .111 Value "You can choose the following functions by selecting "- "with the mouse and pressing MB1" End Literal Literal Text Line 1.500 Column .111 Value "or by using the arrow keys and typing the space or "- "Return keys." End Literal Literal Text Line 2.000 Column .222 Value "Write a Check" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 2.250 Column .222 Value "Deposit" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 2.500 Column .222 Value "Cash" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 2.750 Column .222 Value "Transfer" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 3.000 Column .222 Value "Review" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 3.250 Column .222 Value "Exit" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 2.000 Column 1.700 Value "Displays a check. You type the payee, the amount, and "- "a memo." End Literal Literal Text Line 2.250 Column 1.700 Value "Displays a deposit slip. You type the amount and a memo." End Literal Literal Text Line 2.500 Column 1.700 Value "Displays a menu. You select an amount of cash to "- "withdraw." End Literal Literal Text Line 2.750 Column 1.700 Value "Displays a menu. You transfer between checking and "- "savings." End Literal Literal Text Line 3.000 Column 1.700 Value "Displays a menu. You choose check register or account "- "info." End Literal Literal Text Line 3.250 Column 1.700 Value "Exits from the Sample Checking Application." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel DEPOSIT_PANEL_HELP Viewport HELP_VP Display Viewport Title "Deposit Record Help" Display LABEL_ATTR Remove Literal Text Line .500 Column .222 Value "To make a deposit, you enter the amount of the deposit "- "and, if you wish, a record" End Literal Literal Text Line .750 Column .222 Value "of where you got the money." End Literal Literal Text Line 1.250 Column .222 Value "After entering the amount, select the memo field to "- "enter the memo information." End Literal Literal Text Line 1.500 Column .222 Value "When you are satisfied with both fields, press the OK "- "button or type Ctrl/D to enter" End Literal Literal Text Line 1.750 Column .222 Value "the deposit. To cancel the deposit at any time and "- "return to the choice panel," End Literal Literal Text Line 2.000 Column .222 Value "press the Cancel button or type Ctrl/Q." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel REGISTER_PANEL_HELP Viewport HELP_VP Display Viewport Title "Register Help" Display LABEL_ATTR Remove Literal Text Line .250 Column .222 Value "The register consists of several banking entries. You "- "can read through the " End Literal Literal Text Line .500 Column .222 Value "register list by using the scroll bar, up & down "- "arrows, or (to travel to the next page)" End Literal Literal Text Line .750 Column .222 Value "Previous Panel (Shift/PF3) & Next Panel (Shift/PF4)." End Literal Literal Text Line 1.250 Column .222 Value 'The only information you can change in this panel is '- 'the "Tax Deduction" column; it can be ' End Literal Literal Text Line 1.500 Column .222 Value "either 0 or 1. Return to the choice panel by pressing "- "the OK button or typing Ctrl/D" End Literal Literal Text Line 1.750 Column .222 Value "(to record changes). Press the Cancel button or type "- "Ctrl/Q to cancel any changes." End Literal Literal Text Line 2.250 Column .222 Value "The sample application is designed to handle only 30 "- "register entries; this limit" End Literal Literal Text Line 2.500 Column .222 Value "is not a restriction of DECforms but of the "- "application. When the limit " End Literal Literal Text Line 2.750 Column .222 Value "has been reached, the form does not allow you to "- "choose any of the first " End Literal Literal Text Line 3.000 Column .222 Value "four options on the choice panel, since they all "- "result in register entries." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel REVIEW_PANEL_HELP Viewport HELP_VP Display Viewport Title "Review Help" Display LABEL_ATTR Remove Literal Text Line .500 Column .555 Value "To review the check register, select" End Literal Literal Text Line .500 Column 2.900 Value "Review Register." Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 1.000 Column .555 Value "To review the personal information for the account, "- "select" End Literal Literal Text Line 1.000 Column 4.350 Value "Review Account." Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 1.500 Column .555 Value "Select Cancel or type Ctrl/D to return to the main menu." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel TRANSFER_PANEL_HELP Viewport HELP_VP Display Viewport Title "Transfer Funds Help" Display LABEL_ATTR Remove Literal Text Line .500 Column .333 Value "To transfer funds from checking into savings, select" End Literal Literal Text Line .500 Column 3.750 Value "From checking to savings." Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .750 Column .333 Value "To transfer funds from savings into checking, select" End Literal Literal Text Line .750 Column 3.750 Value "From savings to checking." Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 1.250 Column .333 Value "Specify the amount to be transferred in the amount "- "field. Press the OK button" End Literal Literal Text Line 1.500 Column .333 Value "or type Ctrl/D to enter the transfer; press the Cancel "- "button or type Ctrl/Q to cancel it." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel WELCOME_PANEL_HELP Viewport HELP_VP Display Viewport Title "DECforms Demo Help" Display LABEL_ATTR Remove Literal Text Line .250 Column .222 Value "The Sample Checking Application shows how to use "- "DECforms." End Literal Literal Text Line .750 Column .222 Value "The documentation cites many examples from the "- "Checking Application." End Literal Literal Text Line 1.000 Column .222 Value "This application does not claim to show the" End Literal Literal Text Line 1.000 Column 3.100 Value "best" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 1.000 Column 3.460 Value "way of doing everything." End Literal Literal Text Line 1.250 Column .222 Value "Rather, it shows ways that things" End Literal Literal Text Line 1.250 Column 2.530 Value "can" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 1.250 Column 2.810 Value "be done with DECforms." End Literal Literal Text Line 1.750 Column .222 Value "As you run the rest of the application, you can get "- "help by pressing the HELP button or " End Literal Literal Text Line 2.000 Column .222 Value "typing the HELP KEY. You may cancel any operation by "- "pressing the Cancel button." End Literal Literal Text Line 2.250 Column .222 Value "or by typing Ctrl/Q. To execute any checking "- "operations press the OK button or type Ctrl/D." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .550 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel End Layout Layout CHECKING_ALTERNATE_PIXEL /* This layout shows a further adaptation to the windows styles platforms. Four of the pulldown dialog boxes (panels) are allowed to stay in place and are not removed when their function is completed. The user can then use the NEXT PANEL function to navigate among them or can click on them directly to move focus to them. This is accomplished by declaring a separate viewport for each of the panels, removing the REMOVE clause from the panels, and putting in some code to remember which panels are currently visible (needed so that moving to the "next" panel doesn't accidently bring up a panel that had not yet been displayed). In addition, this layout adds "accelerators" to the main menu. Unfortunately, we can't underline the letters in the Motif layouts yet. That awaits addition of true Menu support in DECforms. This layout adds many customization features to make a shared layout look and behave better on its individual platform. The FOR clause is used heavily in the FUNCTION and ATTRIBUTE statements to customize the keystrokes for the platforms. You'll find a different set of keystrokes for Windows than for Motif because of the different keyboards. The ATTRIBUTE statement customizes the appearance of buttons and menus. Note the use of the system names for colors on the two platforms. You invoke this layout on Motif by setting the logical FORMS$LANGUAGE to "ALTERNATE_PIXEL". */ Device Pixel WORKSTATION Type %Motif End Device Language "ALTERNATE_PIXEL" Units Inches Size 7.600 Lines by 10.000 Columns List STATE_LIST Exactcase "AL" "AK" "AZ" "AR" "CA" "CO" "CT" "DE" "DC" "FL" "GA" "HI" "ID" "IL" "IN" "IA" "KS" "KY" "LA" "ME" "MD" "MA" "MI" "MN" "MS" "MO" "MT" "NE" "NV" "NH" "NJ" "NM" "NY" "NC" "ND" "OH" "OK" "OR" "PA" "RI" "SC" "SD" "TN" "TX" "UT" "VA" "VT" "WA" "WV" "WI" "WY" End List Attribute BUTTON_LABEL_ATTR For WORKSTATION Is Shadow Font Family Menu End Attribute Attribute LABEL_ATTR Is Font Family Times Font Size 12 End Attribute Attribute FAKE_MENU_ATTR For WORKSTATION Is Shadow End Attribute Attribute MENU_BUTTON_LABEL_ACTIVE_ATTR /* Putting a highlight on the menu button may result in a performance loss for certain slower CPUs. The symptom is that the menu item disappears and appears with the new attributes with a noticeable interval. If this bothers you, just leave off the "Active Highlight" clause. */ For WORKSTATION Is Shadow End Attribute Attribute MENU_BUTTON_LABEL_ATTR For WORKSTATION Is Border Width Is .000 NoShadow Font Family Menu End Attribute Attribute PROTECTED_FIELD_ATTR Is Border Width Is .000 NoShadow End Attribute Attribute UNAVAILABLE_ATTR For WORKSTATION Is Foreground Color "Dim Gray" End Attribute Viewport ACCOUNT_VP Lines 2.000 Through 6.250 Columns .750 Through 7.500 Display Viewport IconLabel "Account" Title "Account Information" End Viewport Viewport CASH_VP Lines 1.250 Through 2.850 Columns 3.377 Through 4.677 Display Viewport Title "Cash" End Viewport Viewport CHECK_VP Lines 2.000 Through 7.000 Columns .250 Through 7.590 Display Viewport IconLabel "Check" Title "Write A Check" End Viewport Viewport DEPOSIT_VP Lines 1.500 Through 5.500 Columns .250 Through 6.250 Display Viewport IconLabel "Deposit" Title "Deposit Record" End Viewport Viewport FILE_VP Lines 1.300 Through 1.900 Columns .000 Through 1.600 Display Viewport Title "File" End Viewport Viewport HELP_VP Lines 3.000 Through 7.500 Columns 1.200 Through 8.200 End Viewport Viewport REGISTER_VP Lines 2.000 Through 7.350 Columns .000 Through 10.000 End Viewport Viewport REVIEW_VP Lines 1.250 Through 2.320 Columns 5.500 Through 7.100 Display Viewport Title "Review" End Viewport Viewport TOP_VP Lines .000 Through 1.400 Columns .000 Through 10.000 End Viewport Viewport TRANSFER_VP Lines 2.000 Through 4.450 Columns 4.450 Through 8.200 Display Viewport IconLabel "Transfer" Title "Transfer Funds" End Viewport Viewport WELCOME_VP Lines .000 Through 5.000 Columns .000 Through 7.750 Display Viewport IconLabel "Demo" Title "DECforms Demonstration" End Viewport Function CHOICE_MENU_ACCELERATOR_C /* Cash withdrawal */ Is %ALT + %SMALL_C %ALT + %CAPITAL_C End Function Function CHOICE_MENU_ACCELERATOR_D /* Make a deposit */ Is %ALT + %SMALL_D %ALT + %CAPITAL_D End Function Function CHOICE_MENU_ACCELERATOR_F /* File */ Is %ALT + %SMALL_F %ALT + %CAPITAL_F End Function Function CHOICE_MENU_ACCELERATOR_R /* Review account or register */ Is %ALT + %SMALL_R %ALT + %CAPITAL_R End Function Function CHOICE_MENU_ACCELERATOR_T /* Transfer funds */ Is %ALT + %SMALL_T %ALT + %CAPITAL_T End Function Function CHOICE_MENU_ACCELERATOR_W /* Write a check */ Is %ALT + %SMALL_W %ALT + %CAPITAL_W End Function Function CHOICE_MENU_ACCELERATOR_X /* Exit */ Is %ALT + %SMALL_X %ALT + %CAPITAL_X %ALT + %F4 End Function Function DOWN ITEM /*add arrow to the default*/ For WORKSTATION Is %DOWN %CONTROL + %SHIFT + %PF4 End Function Function LEFT ITEM /*add arrow to the default*/ For WORKSTATION Is %LEFT %CONTROL + %SHIFT + %PF1 End Function Function NEXT ITEM /*Add Tab to Default*/ For WORKSTATION Is %TAB %PF4 End Function Function NEXT PANEL For WORKSTATION Is %SHIFT + %PF4 End Function Function PREVIOUS ITEM /*Add shift-Tab to Default*/ For WORKSTATION Is %SHIFT + %TAB %PF3 End Function Function PREVIOUS PANEL For WORKSTATION Is %SHIFT + %PF3 End Function Function PRINT_FUNCTION Is %CONTROL + %CAPITAL_P %CONTROL + %SMALL_P End Function Function QUIT For WORKSTATION Is %CONTROL + %CAPITAL_Q %CONTROL + %SMALL_Q End Function Function RIGHT ITEM /*add arrow to the default*/ For WORKSTATION Is %RIGHT %CONTROL + %SHIFT + %PF2 End Function Function UP ITEM /*add arrow to the default*/ For WORKSTATION Is %UP %CONTROL + %SHIFT + %PF3 End Function Internal Response CHOOSE_CASH If (CHECKING_BALANCE < 1000) Then Message "You can't withdraw cash because your checking" "account balance is too small." Signal Else Display /*needed to overcome margins bug*/ CASH_PANEL Activate Panel CASH_PANEL Position Immediate To Panel CASH_PANEL End If End Response Internal Response CHOOSE_CHECK /*All the CHOOSE_... internal responses exist so that the given action can be called from either the menu button or from an accelerator*/ If (CHECKING_BALANCE = 0) Then Message "You can't write a check; you have a zero balance." Invalid /*Note that this panel is visible -- used for "next panel" navigation*/ Else Let CHECK_PANEL_VISIBLE = 1 Position Immediate To Panel CHECK_PANEL End If End Response Internal Response CHOOSE_DEPOSIT /*Note that this panel is visible -- used for "next panel" navigation*/ Let DEPOSIT_PANEL_VISIBLE = 1 Position Immediate To Panel DEPOSIT_PANEL End Response Internal Response CHOOSE_EXIT Let OPERATOR_CHOICE = VALUE_EXIT Return Immediate /*Don't validate anything left on the activation list*/ End Response Internal Response CHOOSE_FILE Display /*needed to work around margins bug*/ FILE_PANEL Activate Panel FILE_PANEL Position Immediate To Panel FILE_PANEL End Response Internal Response CHOOSE_REVIEW Display /*needed to work around margins bug*/ REVIEW_PANEL Activate Panel REVIEW_PANEL Position Immediate To Panel REVIEW_PANEL End Response Internal Response CHOOSE_TRANSFER Display /*needed to work around margins bug*/ /*Note that this panel is visible -- used for "next panel" navigation*/ TRANSFER_PANEL Let TRANSFER_PANEL_VISIBLE = 1 Position Immediate To Panel TRANSFER_PANEL End Response Internal Response GOTO_NEXT_PANEL /*We do this override to provide wraparound for panels. If there were a LAST PANEL condition, we would do it differently. Since not, we take advantage of the way Position works: if you try a position and it fails, the previous position remains.*/ Position Immediate To First Panel Position Immediate To Next Panel End Response Internal Response QUIT_ACCOUNT Remove ACCOUNT_VP Position Immediate To Button CHOICE_REVIEW On CHOICE_PANEL /* Note that we are NOT visible so that we can't move to it '- 'with NEXT PANEL*/ Let ACCOUNT_PANEL_VISIBLE = 0 End Response Internal Response QUIT_CHECK Remove CHECK_VP Position Immediate To Button CHOICE_CHECK On CHOICE_PANEL /* Note that we are NOT visible so that we can't move to it '- 'with NEXT PANEL*/ Let CHECK_PANEL_VISIBLE = 0 End Response Internal Response QUIT_DEPOSIT Remove DEPOSIT_VP Position Immediate To Button CHOICE_DEPOSIT On CHOICE_PANEL /* Note that we are NOT visible so that we can't move to it '- 'with NEXT PANEL*/ Let DEPOSIT_PANEL_VISIBLE = 0 End Response Internal Response QUIT_TRANSFER Remove TRANSFER_VP Position Immediate To Button CHOICE_TRANSFER On CHOICE_PANEL /* Note that we are NOT visible so that we can't move to it '- 'with NEXT PANEL*/ Let TRANSFER_PANEL_VISIBLE = 0 End Response Internal Response TOGGLE_XFER_TO_CHK /*Put this in an internal response so that either the toggle symbol or the toggle label can call it*/ Let OPERATOR_CHOICE = VALUE_XFER_TO_CHK Let TO_CHECKING_BUTTON = "@" Let TO_SAVINGS_BUTTON = "O" Position Immediate To Field TRANSFER_PANEL_AMOUNT On TRANSFER_PANEL End Response Internal Response TOGGLE_XFER_TO_SAV /*Put this in an internal response so that either the toggle symbol or the toggle label can call it*/ Let OPERATOR_CHOICE = VALUE_XFER_TO_SAV Let TO_CHECKING_BUTTON = "O" Let TO_SAVINGS_BUTTON = "@" Position Immediate To Field TRANSFER_PANEL_AMOUNT On TRANSFER_PANEL End Response Enable Response Activate Panel WELCOME_PANEL Call "forms_checking_getsysinfo_" Using /*Set the current date since CURRENT_DATE can't be declared with CURRENT attribute*/ By Descriptor USERNAME By Descriptor VERSION Let CURRENT_DATE = TEMP_CURRENT End Response Send Response UPDATE If (NEXT_UPDATE_MESSAGE <> "") Then Message NEXT_UPDATE_MESSAGE ": " NEXT_UPDATE_AMOUNT Reset NEXT_UPDATE_MESSAGE End If If (ROOM_IN_REG = 0) Then Message "The register is full, you can only do reviews now." Signal End If End Response Receive Response ACCOUNT /*In this layout, we allow the user to fill out the change of account panel first and when the user says okay, we return the review value in the choose request to tell the program that an account change is coming. When the program asks for the account update, we just return the information without going to the user any more.*/ Return End Response Receive Response CHOOSE Display /* Need to display to get around margins bug */ CHOICE_PANEL Activate /*We activate all the panels so that they are in order and not intermingled with the choice_panel items. We provide responses to guarantee that only the ones that are supposed to get focus do get it and so that only the panel with focus gets validated.*/ Panel CHOICE_PANEL Panel CHECK_PANEL Panel DEPOSIT_PANEL Panel TRANSFER_PANEL Panel ACCOUNT_PANEL If (OPERATOR_CHOICE = VALUE_CHECK) Then Position To Panel CHECK_PANEL End If If (OPERATOR_CHOICE = VALUE_DEPOSIT) Then Position To Panel DEPOSIT_PANEL End If If (OPERATOR_CHOICE = VALUE_CASH) Then Position To Button CHOICE_CASH On CHOICE_PANEL End If If ((OPERATOR_CHOICE = VALUE_XFER_TO_SAV) OR (OPERATOR_CHOICE = VALUE_XFER_TO_CHK)) Then Position To Panel TRANSFER_PANEL End If If ((OPERATOR_CHOICE = VALUE_REV_REG) OR (OPERATOR_CHOICE = VALUE_REV_ACCOUNT)) Then Position To Button CHOICE_REVIEW On CHOICE_PANEL End If End Response Transceive Response REGISTER_RECORD REGISTER_RECORD Activate Field REGISTER(1:ENTRY_COUNT).REG_TAX_DED on REGISTER_PANEL Button OK_BUTTON on REGISTER_PANEL Button CANCEL_BUTTON on REGISTER_PANEL Button GET_HELP_BUTTON on REGISTER_PANEL Position To Field REGISTER(ENTRY_COUNT).REG_TAX_DED On REGISTER_PANEL End Response Function Response NEXT PANEL Include GOTO_NEXT_PANEL End Response Function Response PREVIOUS PANEL Position Immediate To Last Panel Position Immediate To Previous Panel End Response Function Response PRINT_FUNCTION Message "The print function is not active for this option" Signal End Response Apply Field Default Of Erase on Entry End Default Panel ACCOUNT_PANEL Viewport ACCOUNT_VP Display LABEL_ATTR Entry Response /*If this panel isn't supposed to be visible, go on to next '- 'panel*/ If (ACCOUNT_PANEL_VISIBLE = 0) Then Include GOTO_NEXT_PANEL End If End Response Exit Response Let NEXT_UPDATE_MESSAGE = "" End Response Function Response QUIT Include QUIT_ACCOUNT End Response Validation Response Validate Panel ACCOUNT_PANEL If ( NOT IMMEDIATE) Then Let OPERATOR_CHOICE = VALUE_REV_ACCOUNT Deactivate /*avoid doing any other validation*/ All End If End Response Use Help Panel ACCOUNT_PANEL_HELP Apply Field Default Of Minimum Length 1 Message "You must enter something for " CURRENTITEM Erase on Entry End Default Literal Text Line .170 Column .960 Value "Enter secret password to change the account data:" End Literal Field OP_PASSWORD Line .170 Column 4.560 Entry Response Reset OP_PASSWORD End Response Function Response FOCUS CHANGE /* This function response means you can't go somewhere else via the mouse until this field passes validation. We make an exception for help and cancel. You must either complete the password or cancel. We do this so that we don't have to keep local values for the entries in the panel that are changed before a cancel.*/ If (LOCATORITEM = "CANCEL_BUTTON") Then Position Immediate To Focus Change End If If (LOCATORITEM = "GET_HELP_BUTTON") Then Enter Help Else Position Immediate To Focus Change End If End Response Concealed Input Picture X(12) Use Help Message "Enter the secret word to change the account data." " (Hint: try Help again.)" Require (OP_PASSWORD = PASSWORD) Message "You must enter the right password to change the data. " "Hint: click on the HELP button." End Field Literal Rectangle Line .519 Column .077 Line 3.400 Column 6.530 End Literal Literal Text Line .730 Column 3.780 Value "Account Number " End Literal Field ACCOUNT_NUMBER Line .730 Column 5.140 Display PROTECTED_FIELD_ATTR Output Picture 9(5) Protected End Field Literal Text Line .960 Column 3.780 Value "Opened" End Literal Field DATE_ESTABLISHED Line .960 Column 5.140 Display PROTECTED_FIELD_ATTR Output Picture For Date NN/DD/YYYY Protected End Field Literal Text Line .727 Column .285 Value "NAME" End Literal Literal Text Line .974 Column .467 Value "Last" End Literal Field LAST_NAME Line .974 Column .974 Output Picture X(20) End Field Literal Text Line 1.286 Column .467 Value "First" End Literal Field FIRST_NAME Line 1.286 Column .974 Output Picture X(15) End Field Literal Text Line 1.598 Column .467 Value "Middle" End Literal Field MIDDLE_NAME Line 1.598 Column .974 Output Picture X(15) No Minimum Length End Field Literal Text Line 2.052 Column .285 Value "ADDRESS" End Literal Literal Text Line 2.286 Column .467 Value "Street" End Literal Field STREET Line 2.286 Column .974 Output Picture X(30) End Field Literal Text Line 2.585 Column .467 Value "City" End Literal Field CITY Line 2.585 Column .974 Output Picture X(20) End Field Literal Text Line 2.884 Column .467 Value "State" End Literal Field STATE Line 2.884 Column .974 Width .400 Output Picture X(2) Uppercase Minimum Length 2 Message "State field must be two letters" Search STATE_LIST Message "Must be one of the fifty U.S.A. states or DC." End Field Literal Text Line 2.884 Column 1.830 Value "Zip" End Literal Field ZIP_CODE Line 2.884 Column 2.200 Output Picture 9(5) Require (ZIP_CODE >= 100) Message "Zip code region must be at least 1; " "that means the zip code must be 100 or more." End Field Literal Text Line 2.052 Column 3.819 Value "PHONE" End Literal Literal Text Line 2.286 Column 4.079 Value "Home" End Literal Field HOME_PHONE Line 2.286 Column 4.729 Output Picture '('999')'999'-'9999 Minimum Length 10 Message "You must supply home phone number, " "including area code." End Field Literal Text Line 2.585 Column 4.079 Value "Business" End Literal Field WORK_PHONE Line 2.585 Column 4.729 Output Picture '('999')'999'-'9999 No Minimum Length Range 0 Through 0 1000000000 Through 9999999999 Message "Business phone must be null or all 10 digits" End Field Push Button OK_BUTTON Line 3.494 Column .779 Height .450 Width 1.500 Function Response TRIGGER OBJECT Let NEXT_UPDATE_MESSAGE = "" Return End Response Display BUTTON_LABEL_ATTR Label "OK" End Button Push Button CANCEL_BUTTON Line 3.494 Column 2.520 Height .450 Width 1.500 Function Response TRIGGER OBJECT Include QUIT_ACCOUNT End Response Display BUTTON_LABEL_ATTR Label "Cancel" End Button Push Button GET_HELP_BUTTON Line 3.494 Column 4.261 Height .450 Width 1.500 Function Response TRIGGER OBJECT Enter Help End Response Function Response NEXT ITEM Position To Field LAST_NAME On ACCOUNT_PANEL End Response Display BUTTON_LABEL_ATTR Label "Help" End Button End Panel Panel CASH_PANEL Viewport CASH_VP Display MENU_BUTTON_LABEL_ATTR Remove No Scrollbars Exit Response Deactivate Panel CASH_PANEL If (AMOUNT = 0) Then /*if amount is zero on exit, operator made no choice*/ Message "Quitting -- no cash withdrawn." /*Leaving because operator made a choice*/ Else Deactivate /*avoid validating the other panels*/ All Let OPERATOR_CHOICE = VALUE_CASH Let MEMO = "*Cash withdrawal*" Let NEXT_UPDATE_MESSAGE = "Cash withdrawal made against "- "your checking account" End If End Response Function Response QUIT Position Immediate To Button CHOICE_CASH On CHOICE_PANEL End Response Function Response NEXT PANEL /*Ignore such requests*/ End Response Function Response PREVIOUS PANEL /*Ignore such requests*/ End Response Use Help Panel CASH_PANEL_HELP Apply Field Default Of Active Highlight MENU_BUTTON_LABEL_ACTIVE_ATTR End Default Push Button CHOICE_CASH_10 Line .000 Column .000 Height .260 Width 1.200 Function Response TRIGGER OBJECT Let AMOUNT = 1000 Let NEXT_UPDATE_AMOUNT = "$10" Return End Response Function Response UP ITEM /*Wrap around*/ Position To Button CANCEL_BUTTON On CASH_PANEL End Response Function Response PREVIOUS ITEM Position To Button CANCEL_BUTTON On CASH_PANEL End Response Highlight UNAVAILABLE_ATTR When (CHECKING_BALANCE < 1000) Protected When (CHECKING_BALANCE < 1000) Label " $10" End Button Push Button CHOICE_CASH_20 Line .250 Column .000 Height .260 Width 1.200 Function Response TRIGGER OBJECT Let AMOUNT = 2000 Let NEXT_UPDATE_AMOUNT = "$20" Return End Response Highlight UNAVAILABLE_ATTR When (CHECKING_BALANCE < 2000) Protected When (CHECKING_BALANCE < 2000) Label " $20" End Button Push Button CHOICE_CASH_50 Line .500 Column .000 Height .260 Width 1.200 Function Response TRIGGER OBJECT Let AMOUNT = 5000 Let NEXT_UPDATE_AMOUNT = "$50" Return End Response Highlight UNAVAILABLE_ATTR When (CHECKING_BALANCE < 5000) Protected When (CHECKING_BALANCE < 5000) Label " $50" End Button Push Button CHOICE_CASH_100 Line .750 Column .000 Height .260 Width 1.200 Function Response TRIGGER OBJECT Let AMOUNT = 10000 Let NEXT_UPDATE_AMOUNT = "$100" Return End Response Highlight UNAVAILABLE_ATTR When (CHECKING_BALANCE < 10000) Protected When (CHECKING_BALANCE < 10000) Label "$100" End Button Push Button CANCEL_BUTTON Line 1.000 Column .000 Height .260 Width 1.200 Function Response TRIGGER OBJECT Position Immediate To Button CHOICE_CASH On CHOICE_PANEL End Response Function Response DOWN ITEM /*Wrap around*/ Position Immediate To Button CHOICE_CASH_10 On CASH_PANEL End Response Function Response NEXT ITEM Position Immediate To Button CHOICE_CASH_10 On CASH_PANEL End Response Label "Cancel" End Button End Panel Panel CHECK_PANEL Viewport CHECK_VP Display LABEL_ATTR Entry Response /*If this panel isn't supposed to be visible, go on to next '- 'panel*/ If (CHECK_PANEL_VISIBLE = 0) Then Include GOTO_NEXT_PANEL End If End Response Exit Response /* There several reasons we could be leaving the panel. -- The operator pressed the QUIT key or clicked on cancel or clicked on another panel. In any of these cases, there was a POSITION IMMEDIATE. -- The operator pressed the TRANSMIT key or clicked on okay. We're done with a record so we make some assignments for the record being sent back and for the action the next time the update record comes in. Just in case it was the TRANSMIT/OKAY case, we set some variables that are transferred back or saved for next request. */ Let AMOUNT = CHECK_PANEL_AMOUNT Let NEXT_UPDATE_AMOUNT = CHECK_FIELDIMAGE Let MEMO = CHECK_PANEL_MEMO Let OPERATOR_CHOICE = VALUE_CHECK Let NEXT_UPDATE_MESSAGE = "Check Paid" End Response Function Response QUIT Include QUIT_CHECK End Response Function Response PRINT_FUNCTION Validate Panel CHECK_PANEL If ( NOT IMMEDIATE) Then /* print and return only if the check is okay */ Print CHECK_PANEL Message "The check has been printed to a file " Return End If End Response Validation Response Validate Panel CHECK_PANEL If ( NOT IMMEDIATE) Then Deactivate /*Avoid validating other panels*/ All End If End Response Use Help Panel CHECK_PANEL_HELP Literal Rectangle Line .441 Column .129 Line 3.691 Column 7.014 End Literal Field CHECK_NUMBER Line .584 Column 5.859 Display PROTECTED_FIELD_ATTR Output Picture 9999R9 Protected End Field Field MAIL_NAME Line .584 Column .311 Display PROTECTED_FIELD_ATTR Protected End Field Field STREET Line .844 Column .311 Display PROTECTED_FIELD_ATTR Protected End Field Field MAIL_CSZ Line 1.091 Column .311 Display PROTECTED_FIELD_ATTR Protected End Field Field HOME_PHONE Line 1.338 Column .311 Display PROTECTED_FIELD_ATTR Output Picture 'Home ('999')'999'-'9999 Protected End Field Field WORK_PHONE Line 1.338 Column 2.416 Concealed When (WORK_PHONE = 0) Display PROTECTED_FIELD_ATTR Output Picture 'Office ('999')'999'-'9999 Protected End Field Literal Text Line 1.598 Column 4.742 Value "Date:" End Literal Field CURRENT_DATE Line 1.598 Column 5.209 Display PROTECTED_FIELD_ATTR Output Picture For Date MMMMMMMMMQ' 'DDQ', 'YYYY Protected End Field Literal Text Line 2.091 Column .428 Value "Pay to" End Literal Field CHECK_PANEL_MEMO Line 2.065 Column .974 Function Response PREVIOUS ITEM /*Wrap around since this is the first field on the panel*/ Position To Button GET_HELP_BUTTON On CHECK_PANEL End Response Output Picture X(35) Use Help Message "Enter the person or organization to whom you" " wish to pay the check." Minimum Length 1 Message "You must fill in the payee." End Field Literal Text Line 2.091 Column 4.742 Value "Amount $" End Literal Field CHECK_PANEL_AMOUNT Line 2.091 Column 5.625 Exit Response Let CHECK_FIELDIMAGE = FIELDIMAGE End Response Output Picture 999,99R9.99 Scale -2 Replace Leading "*" Use Help Message "Enter the amount to be paid." Range 0 Through CHECKING_BALANCE Message "Check amount must be less than the checking "- "account balance." Require (CHECK_PANEL_AMOUNT > 0) Message "Check amount must be greater than zero." End Field Literal Text Line 2.585 Column .428 Value "Memo" End Literal Field CHECK_MEMO Line 2.585 Column .974 Output Picture X(35) Use Help Message "Fill in a reminder to yourself about what the" " check is for. You need not fill this in." End Field Literal Text Line 3.338 Column .428 Value "FIRST NATIONAL BANK" Display Font Weight Bold End Literal Literal Text Line 3.338 Column 4.742 Value "Account" End Literal Field ACCOUNT_NUMBER Line 3.338 Column 5.625 Display PROTECTED_FIELD_ATTR Output Picture 9(5) Protected End Field Push Button OK_BUTTON Line 4.092 Column .909 Height .450 Width 1.500 Function Response TRIGGER OBJECT Return End Response Display BUTTON_LABEL_ATTR Label "OK" End Button Push Button CANCEL_BUTTON Line 4.092 Column 2.650 Height .450 Width 1.500 Function Response TRIGGER OBJECT Include QUIT_CHECK End Response Display BUTTON_LABEL_ATTR Label "Cancel" End Button Push Button GET_HELP_BUTTON Line 4.092 Column 4.404 Height .450 Width 1.500 Function Response TRIGGER OBJECT Enter Help End Response Function Response NEXT ITEM /*Wrap around since this is the last item on the panel*/ Position To Field CHECK_PANEL_MEMO On CHECK_PANEL End Response Display BUTTON_LABEL_ATTR Label "Help" End Button End Panel Panel CHOICE_PANEL Viewport TOP_VP Display Viewport IconLabel "Checking Demo" Title "DECforms Demo: Your Checking Account" Display MENU_BUTTON_LABEL_ATTR Function Response TRANSMIT /*Means nothing at this point*/ End Response Function Response NEXT ITEM If PANEL LAST ITEM Then Position To Panel CHOICE_PANEL Else Position To Next Item End If End Response Function Response PREVIOUS ITEM If PANEL FIRST ITEM Then Position To Button GET_HELP_BUTTON On CHOICE_PANEL Else Position To Previous Item End If End Response Function Response RIGHT ITEM If PANEL LAST ITEM Then Position To Panel CHOICE_PANEL Else Position To Next Item End If End Response Function Response LEFT ITEM If PANEL FIRST ITEM Then Position To Button GET_HELP_BUTTON On CHOICE_PANEL Else Position To Previous Item End If End Response Function Response CHOICE_MENU_ACCELERATOR_F /* File */ Include CHOOSE_FILE End Response Function Response CHOICE_MENU_ACCELERATOR_W /* Write a check */ Include CHOOSE_CHECK End Response Function Response CHOICE_MENU_ACCELERATOR_D /* Make a deposit */ Include CHOOSE_DEPOSIT End Response Function Response CHOICE_MENU_ACCELERATOR_C /* Cash withdrawal */ Include CHOOSE_CASH End Response Function Response CHOICE_MENU_ACCELERATOR_T /* Transfer funds */ Include CHOOSE_TRANSFER End Response Function Response CHOICE_MENU_ACCELERATOR_R /* Review account or register */ Include CHOOSE_REVIEW End Response Function Response CHOICE_MENU_ACCELERATOR_X /* Exit */ Include CHOOSE_EXIT End Response Use Help Panel CHOICE_PANEL_HELP Apply Field Default Of Active Highlight MENU_BUTTON_LABEL_ACTIVE_ATTR End Default Push Button CHOICE_FILE Line .100 Column .150 Height .300 Width .500 Function Response TRIGGER OBJECT Include CHOOSE_FILE End Response Function Response UP ITEM Include CHOOSE_FILE End Response Function Response DOWN ITEM Include CHOOSE_FILE End Response Label " File " End Button Push Button CHOICE_CHECK Line .100 Column .766 Height .300 Width 1.300 Function Response TRIGGER OBJECT Include CHOOSE_CHECK End Response Function Response UP ITEM Include CHOOSE_CHECK End Response Function Response DOWN ITEM Include CHOOSE_CHECK End Response Highlight UNAVAILABLE_ATTR When (ROOM_IN_REG = 0) Protected When (ROOM_IN_REG = 0) Label " Write a check " End Button Push Button CHOICE_DEPOSIT Line .100 Column 2.221 Height .300 Width 1.000 Function Response TRIGGER OBJECT Include CHOOSE_DEPOSIT End Response Function Response UP ITEM Include CHOOSE_DEPOSIT End Response Function Response DOWN ITEM Include CHOOSE_DEPOSIT End Response Highlight UNAVAILABLE_ATTR When (ROOM_IN_REG = 0) Protected When (ROOM_IN_REG = 0) Label " Deposit " End Button Push Button CHOICE_CASH Line .100 Column 3.377 Height .300 Width .750 Function Response TRIGGER OBJECT Include CHOOSE_CASH End Response Function Response UP ITEM Include CHOOSE_CASH End Response Function Response DOWN ITEM Include CHOOSE_CASH End Response Highlight UNAVAILABLE_ATTR When (ROOM_IN_REG = 0) Protected When (ROOM_IN_REG = 0) Label " Cash " End Button Push Button CHOICE_TRANSFER Line .100 Column 4.326 Height .300 Width 1.000 Function Response TRIGGER OBJECT Include CHOOSE_TRANSFER End Response Function Response UP ITEM Include CHOOSE_TRANSFER End Response Function Response DOWN ITEM Include CHOOSE_TRANSFER End Response Highlight UNAVAILABLE_ATTR When (ROOM_IN_REG = 0) Protected When (ROOM_IN_REG = 0) Label " Transfer " End Button Push Button CHOICE_REVIEW Line .100 Column 5.430 Height .300 Width 1.000 Function Response TRIGGER OBJECT Include CHOOSE_REVIEW End Response Function Response UP ITEM Include CHOOSE_REVIEW End Response Function Response DOWN ITEM Include CHOOSE_REVIEW End Response Label " Review " End Button Push Button GET_HELP_BUTTON Line .100 Column 8.500 Height .300 Width .666 Function Response TRIGGER OBJECT Enter Help End Response Function Response UP ITEM Enter Help End Response Function Response DOWN ITEM Enter Help End Response Label " Help " End Button Push Button MENU_BACKGROUND /*This push button lies under the above buttons and makes them look like a fake menu*/ Line .000 Column .000 Height .500 Width 9.750 Display FAKE_MENU_ATTR Protected Label "" End Button Literal Text Line .600 Column 6.600 Value "Balances:" Display LABEL_ATTR End Literal Literal Text Line .600 Column 7.300 Value "Checking:" Display LABEL_ATTR End Literal Field CHECKING_BALANCE Line .600 Column 8.000 Display PROTECTED_FIELD_ATTR Font Family Courier Font Size 10 Output Picture 99,999,99W9.99 Scale -2 Protected End Field Literal Text Line .800 Column 7.300 Value "Savings: " Display LABEL_ATTR End Literal Field SAVINGS_BALANCE Line .800 Column 8.000 Display PROTECTED_FIELD_ATTR Font Family Courier Font Size 10 Output Picture 99,999,99W9.99 Scale -2 Protected End Field End Panel Panel DEPOSIT_PANEL Viewport DEPOSIT_VP Display LABEL_ATTR Entry Response /*If this panel isn't supposed to be visible, go on to next '- 'panel*/ If (DEPOSIT_PANEL_VISIBLE = 0) Then Include GOTO_NEXT_PANEL End If End Response Exit Response /* There several reasons we could be leaving the panel. -- The operator pressed the QUIT key or clicked on cancel or clicked on another panel. In any of these cases, there was a POSITION IMMEDIATE. -- The operator pressed the TRANSMIT key or clicked on okay. We're done with a record so we make some assignments for the record being sent back and for the action the next time the update record comes in. Just in case it was the TRANSMIT/OKAY case, we set some variables that are transferred back or saved for next request. */ Let AMOUNT = DEPOSIT_PANEL_AMOUNT Let NEXT_UPDATE_AMOUNT = DEPOSIT_FIELDIMAGE Let MEMO = DEPOSIT_PANEL_MEMO Let OPERATOR_CHOICE = VALUE_DEPOSIT Let NEXT_UPDATE_MESSAGE = "Deposit credited to your checking "- "account" End Response Function Response QUIT Include QUIT_DEPOSIT End Response Function Response PRINT_FUNCTION Validate Panel DEPOSIT_PANEL If ( NOT IMMEDIATE) Then /* print only if the deposit is okay */ Print DEPOSIT_PANEL Message "The deposit slip has been printed to a file " Return End If End Response Validation Response Validate Panel DEPOSIT_PANEL If ( NOT IMMEDIATE) Then Deactivate /*Avoid validating other panels*/ All End If End Response Use Help Panel DEPOSIT_PANEL_HELP Literal Rectangle Line .363 Column .155 Line 2.727 Column 5.741 End Literal Literal Text Line .506 Column .558 Value "Date:" End Literal Field CURRENT_DATE Line .506 Column 1.221 Display PROTECTED_FIELD_ATTR Output Picture For Date MMMMMMMMMQ' 'DDQ', 'YYYY Protected End Field Literal Text Line .506 Column 3.793 Value "Account" End Literal Field ACCOUNT_NUMBER Line .506 Column 4.677 Display PROTECTED_FIELD_ATTR Output Picture 9(5) Protected End Field Literal Text Line 1.260 Column .857 Value "Deposit $" End Literal Field DEPOSIT_PANEL_AMOUNT Line 1.260 Column 1.974 Exit Response Let DEPOSIT_FIELDIMAGE = FIELDIMAGE End Response Function Response PREVIOUS ITEM /*Wrap around since this is first item on panel*/ Position To Button GET_HELP_BUTTON On DEPOSIT_PANEL End Response Output Picture 9,99R9.99 Scale -2 Use Help Message "Enter the amount of the deposit." Require (DEPOSIT_PANEL_AMOUNT > 0) Message "You must specify a non-zero deposit amount." End Field Literal Text Line 1.766 Column .857 Value "Memo" End Literal Field DEPOSIT_PANEL_MEMO Line 1.766 Column 1.974 Output Picture X(35) Use Help Message "Fill in a reminder of where you got the money." End Field Push Button OK_BUTTON Line 3.053 Column .441 Height .450 Width 1.500 Function Response TRIGGER OBJECT Return End Response Display BUTTON_LABEL_ATTR Label "OK" End Button Push Button CANCEL_BUTTON Line 3.053 Column 2.182 Height .450 Width 1.500 Function Response TRIGGER OBJECT Include QUIT_DEPOSIT End Response Display BUTTON_LABEL_ATTR Label "Cancel" End Button Push Button GET_HELP_BUTTON Line 3.053 Column 3.936 Height .450 Width 1.500 Function Response TRIGGER OBJECT Enter Help End Response Function Response NEXT ITEM /*Wrap around since this is last item on panel*/ Position To Field DEPOSIT_PANEL_AMOUNT On DEPOSIT_PANEL End Response Display BUTTON_LABEL_ATTR Label "Help" End Button End Panel Panel FILE_PANEL Viewport FILE_VP Display MENU_BUTTON_LABEL_ATTR Remove No Scrollbars Exit Response Deactivate Panel FILE_PANEL End Response Function Response QUIT Position Immediate To Panel CHOICE_PANEL End Response Apply Field Default Of Active Highlight MENU_BUTTON_LABEL_ACTIVE_ATTR End Default Push Button CHOICE_EXIT Line .000 Column .000 Height .300 Width 1.500 Function Response TRIGGER OBJECT Include CHOOSE_EXIT End Response Active Highlight MENU_BUTTON_LABEL_ACTIVE_ATTR Label "Exit Alt+X" End Button End Panel Panel REGISTER_PANEL Viewport REGISTER_VP Display Viewport Title "Register: Deposits and Withdrawals" Display LABEL_ATTR PROTECTED_FIELD_ATTR Remove Exit Response Let NEXT_UPDATE_MESSAGE = "" If IMMEDIATE Then Message "Quitting -- no update made to the register." Return Immediate "EFQUT" End If End Response Function Response QUIT Return Immediate "EFQUT" End Response Validation Response Validate Panel REGISTER_PANEL End Response Use Help Panel REGISTER_PANEL_HELP Apply Field Default Of Protected End Default Literal Text Line .200 Column .111 Value "Check" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column .111 Value "Num" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column .666 Value "Date" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column 1.665 Value "Check Payee or Deposit Memo" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column 5.522 Value "Chk Amt" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column 6.521 Value "Dep Amt" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column 7.520 Value "Balance" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .200 Column 8.408 Value "Tax" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .450 Column 8.408 Value "Ded" Display Font Weight Bold LABEL_ATTR End Literal Group REGISTER Vertical Displays 10 First REGISTER_FIRST Scroll By Page Line .700 Column .111 Height .320 Function Response DOWN ITEM If LAST OCCURRENCE VERTICAL Then Message "End of register" Signal Else Position To Down Occurrence End If End Response Function Response UP ITEM If FIRST OCCURRENCE VERTICAL Then Message "Beginning of register" Signal Else Position To Up Occurrence End If End Response Function Response NEXT PANEL If LAST OCCURRENCE VERTICAL Then Message "End of register" Signal Else Position To Down Occurrence Unseen End If End Response Function Response PREVIOUS PANEL If FIRST OCCURRENCE VERTICAL Then Message "Beginning of register" Signal Else Position To Up Occurrence Unseen End If End Response Field REG_CHK_NUM Line .000 Column .000 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture 9999R End Field Field REG_DATE Line .000 Column .555 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture For Date NN/DD/YY End Field Field REG_MEM Line .000 Column 1.554 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture X(35) End Field Field REG_PAY Line .000 Column 5.272 Concealed When (REGISTER(**).REG_PAY >= 0) Output Picture 9,999R.99 Scale -2 End Field Field REG_AMOUNT Line .000 Column 6.271 Concealed When (REGISTER(**).REG_AMOUNT <= 0) Output Picture 9,999R.99 Scale -2 End Field Field REG_BALANCE Line .000 Column 7.120 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture 99,999R.99 Scale -2 End Field Field REG_TAX_DED Line .000 Column 8.408 Concealed When (REGISTER(**).REG_AMOUNT = 0) Output Picture 9 Not Protected Range 0 Through 1 Erase on Entry End Field Literal Polyline Line .300 Column .100 Line .300 Column 8.500 End Literal End Group Literal Text Line 4.000 Column .222 Value "You may change only the tax deduction column, to 0 or 1." Display Font Weight Bold LABEL_ATTR End Literal Push Button OK_BUTTON Line 4.350 Column 2.119 Height .450 Width 1.500 Apply No Field Default Function Response TRIGGER OBJECT Return End Response Display BUTTON_LABEL_ATTR Label "OK" End Button Push Button CANCEL_BUTTON Line 4.350 Column 3.869 Height .450 Width 1.500 Apply No Field Default Function Response TRIGGER OBJECT Return Immediate "EFQUT" End Response Display BUTTON_LABEL_ATTR Label "Cancel" End Button Push Button GET_HELP_BUTTON Line 4.350 Column 5.619 Height .450 Width 1.500 Apply No Field Default Function Response TRIGGER OBJECT Enter Help End Response Display BUTTON_LABEL_ATTR Label "Help" End Button End Panel Panel REVIEW_PANEL Viewport REVIEW_VP Display MENU_BUTTON_LABEL_ATTR Remove No Scrollbars Exit Response Deactivate Panel REVIEW_PANEL If ( NOT IMMEDIATE) Then Deactivate /*avoid validating the other panels*/ All End If End Response Function Response QUIT Position Immediate To Button CHOICE_REVIEW On CHOICE_PANEL End Response Function Response NEXT PANEL Position Immediate To Button CHOICE_REVIEW On CHOICE_PANEL End Response Function Response PREVIOUS PANEL Position Immediate To Button CHOICE_REVIEW On CHOICE_PANEL End Response Use Help Panel REVIEW_PANEL_HELP Apply Field Default Of Active Highlight MENU_BUTTON_LABEL_ACTIVE_ATTR End Default Push Button CHOICE_REV_REG Line .000 Column .000 Height .250 Width 1.500 Function Response TRIGGER OBJECT Let OPERATOR_CHOICE = VALUE_REV_REG Return End Response Function Response UP ITEM Position Immediate To Button CANCEL_BUTTON On REVIEW_PANEL End Response Function Response PREVIOUS ITEM Position Immediate To Button CANCEL_BUTTON On REVIEW_PANEL End Response Label "Review Register" End Button Push Button CHOICE_REV_ACCOUNT Line .260 Column .000 Height .250 Width 1.500 Function Response TRIGGER OBJECT Let ACCOUNT_PANEL_VISIBLE = 1 Position Immediate To Panel ACCOUNT_PANEL End Response Label "Review Account" End Button Push Button CANCEL_BUTTON Line .520 Column .000 Height .250 Width 1.500 Function Response TRIGGER OBJECT Position Immediate To Panel CHOICE_PANEL End Response Function Response NEXT ITEM Position Immediate To Button CHOICE_REV_REG On REVIEW_PANEL End Response Function Response DOWN ITEM Position Immediate To Button CHOICE_REV_REG On REVIEW_PANEL End Response Label "Cancel " End Button End Panel Panel TRANSFER_PANEL Viewport TRANSFER_VP Display LABEL_ATTR Entry Response /* Set the operator_choice variable according to the setting of the toggles */ If (TO_CHECKING_BUTTON = "@") Then /*If this panel isn't supposed to be visible, go on to '- 'next panel*/ Let OPERATOR_CHOICE = VALUE_XFER_TO_CHK Else If (TO_SAVINGS_BUTTON = "@") Then Let OPERATOR_CHOICE = VALUE_XFER_TO_SAV Else Let OPERATOR_CHOICE = 0 End If End If If (TRANSFER_PANEL_VISIBLE = 0) Then Include GOTO_NEXT_PANEL End If End Response Exit Response /* There several reasons we could be leaving the panel. -- The operator pressed the QUIT key or clicked on cancel or clicked on another panel. In any of these cases, there was a POSITION IMMEDIATE. -- The operator pressed the TRANSMIT key or clicked on okay. We're done with a record so we make some assignments for the record being sent back and for the action the next time the update record comes in. Just in case it was the TRANSMIT/OKAY case, we set some variables that are transferred back or saved for next request. */ Let AMOUNT = TRANSFER_PANEL_AMOUNT Let NEXT_UPDATE_AMOUNT = TRANSFER_FIELDIMAGE If (OPERATOR_CHOICE = VALUE_XFER_TO_CHK) Then Let NEXT_UPDATE_MESSAGE = "Money transferred from savings "- "to checking" Let MEMO = "*Transfer from savings to checking*" Else If (OPERATOR_CHOICE = VALUE_XFER_TO_CHK) Then Let NEXT_UPDATE_MESSAGE = "Money transferred from "- "checking to savings" Let MEMO = "*Transfer from checking to savings*" End If End If End Response Function Response QUIT Include QUIT_TRANSFER End Response Function Response LEFT ITEM End Response Function Response RIGHT ITEM End Response Validation Response If (OPERATOR_CHOICE = 0) Then Invalid Position Immediate To Button CHOICE_XFER_TO_SAV On TRANSFER_PANEL Message "You must specify a direction and an amount or you "- "must cancel." Else Validate Field TRANSFER_PANEL_AMOUNT on TRANSFER_PANEL End If If ( NOT IMMEDIATE) Then Deactivate All End If End Response Use Help Panel TRANSFER_PANEL_HELP Push Button CHOICE_XFER_TO_SAV Line .150 Column .750 Height .350 Width 2.300 Function Response TRIGGER OBJECT Include TOGGLE_XFER_TO_SAV End Response Function Response PREVIOUS ITEM /*Wrap around since this is first item on panel*/ Position Immediate To Button GET_HELP_BUTTON On TRANSFER_PANEL End Response Function Response NEXT ITEM Position Immediate To Button CHOICE_XFER_TO_CHK On TRANSFER_PANEL End Response Function Response DOWN ITEM Position Immediate To Button CHOICE_XFER_TO_CHK On TRANSFER_PANEL End Response Display MENU_BUTTON_LABEL_ATTR Label " From checking to savings " End Button Push Button PB_TO_SAVINGS_BUTTON /*We set up the responses for CHOICE_XFER_TO_SAV so that this button never gets focus except on a direct click*/ Line .150 Column .500 Width .350 Function Response TRIGGER OBJECT Include TOGGLE_XFER_TO_SAV End Response Display PROTECTED_FIELD_ATTR Label TO_SAVINGS_BUTTON End Button Push Button CHOICE_XFER_TO_CHK Line .600 Column .750 Height .350 Width 2.300 Function Response TRIGGER OBJECT Include TOGGLE_XFER_TO_CHK End Response Function Response NEXT ITEM Position Immediate To Field TRANSFER_PANEL_AMOUNT On TRANSFER_PANEL End Response Function Response DOWN ITEM Position Immediate To Field TRANSFER_PANEL_AMOUNT On TRANSFER_PANEL End Response Function Response PREVIOUS ITEM Position Immediate To Button CHOICE_XFER_TO_SAV On TRANSFER_PANEL End Response Function Response UP ITEM Position Immediate To Button CHOICE_XFER_TO_SAV On TRANSFER_PANEL End Response Display MENU_BUTTON_LABEL_ATTR Label " From savings to checking " End Button Push Button PB_TO_CHECKING_BUTTON /*We set up the responses for CHOICE_XFER_TO_CHK and TRANSFER_PANEL_AMOUNT so that this button never gets focus except on a direct click*/ Line .600 Column .500 Width .350 Function Response TRIGGER OBJECT Include TOGGLE_XFER_TO_CHK End Response Display PROTECTED_FIELD_ATTR Label TO_CHECKING_BUTTON End Button Literal Text Line 1.150 Column .500 Value "Amount $" End Literal Field TRANSFER_PANEL_AMOUNT Line 1.150 Column 1.500 Exit Response Let TRANSFER_FIELDIMAGE = FIELDIMAGE End Response Function Response UP ITEM Position Immediate To Button CHOICE_XFER_TO_CHK On TRANSFER_PANEL End Response Function Response PREVIOUS ITEM Position Immediate To Button CHOICE_XFER_TO_CHK On TRANSFER_PANEL End Response Validation Response If (OPERATOR_CHOICE = VALUE_XFER_TO_SAV) Then If (TRANSFER_PANEL_AMOUNT > CHECKING_BALANCE) Then Message "Transfer amount must be less than the " "checking account balance." Invalid Signal End If Else If (OPERATOR_CHOICE = VALUE_XFER_TO_CHK) Then If (TRANSFER_PANEL_AMOUNT > SAVINGS_BALANCE) Then Message "Transfer amount must be less than the " "savings account balance." Invalid Signal End If End If End If End Response Display LABEL_ATTR Output Picture 999,99R9.99 Scale -2 Use Help Message "Enter the amount to transfer." Require (TRANSFER_PANEL_AMOUNT > 0) Message "Transfer amount must be greater than zero." End Field Push Button OK_BUTTON Line 1.673 Column .410 Height .450 Width .750 Function Response TRIGGER OBJECT Return End Response Display BUTTON_LABEL_ATTR Label "OK" End Button Push Button CANCEL_BUTTON Line 1.673 Column 1.540 Height .450 Width .750 Function Response TRIGGER OBJECT Include QUIT_TRANSFER End Response Display BUTTON_LABEL_ATTR Label "Cancel" End Button Push Button GET_HELP_BUTTON Line 1.673 Column 2.660 Height .450 Width .750 Function Response TRIGGER OBJECT Enter Help End Response Function Response NEXT ITEM /*Wrap around since this is first item on panel*/ Position Immediate To Button CHOICE_XFER_TO_CHK On TRANSFER_PANEL End Response Display BUTTON_LABEL_ATTR Label "Help" End Button End Panel Panel WELCOME_PANEL Viewport WELCOME_VP Display LABEL_ATTR Remove Function Response NEXT HELP Enter Help End Response Use Help Panel WELCOME_PANEL_HELP Literal Text Line .500 Column 2.997 Value "Welcome to the" Display Font Size 18 End Literal Literal Text Line 1.000 Column 2.988 Value "DECforms V3.3" Display Font Size 18 Font Weight Bold End Literal Literal Text Line 1.507 Column 1.987 Value "Sample Checking Application" Display Font Size 24 End Literal Literal Text Line 2.182 Column 3.118 Value "Your Personal" Display Font Size 18 End Literal Literal Text Line 2.572 Column 2.910 Value "Checking Account" Display Font Size 18 End Literal Literal Text Line 4.000 Column .444 Value "On " End Literal Field VERSION Line 4.000 Column .777 Display PROTECTED_FIELD_ATTR Protected End Field Literal Text Line 4.250 Column .444 Value "For user name: " End Literal Field USERNAME Line 4.250 Column 1.887 Display PROTECTED_FIELD_ATTR Protected End Field Push Button CONTINUE_BUTTON Line 3.884 Column 4.079 Height .550 Width 1.500 Function Response TRIGGER OBJECT Return End Response Display BUTTON_LABEL_ATTR Label "Continue" End Button Push Button GET_HELP_BUTTON Line 3.871 Column 5.833 Height .550 Width 1.500 Function Response TRIGGER OBJECT Enter Help End Response Display BUTTON_LABEL_ATTR Label "Help" End Button End Panel Help Panel ACCOUNT_PANEL_HELP Viewport HELP_VP Display Viewport Title "Account Information Help" Display LABEL_ATTR Remove Literal Text Line .250 Column .111 Value "If you know the password, you can change the data "- "recorded (everything except the" End Literal Literal Text Line .500 Column .111 Value "account number and the date the account was opened). "- "If you want to change any" End Literal Literal Text Line .750 Column .111 Value "account data, enter the secret password and press the "- "Tab key." End Literal Literal Text Line 1.250 Column .111 Value "If the password is accepted, you can change any of the "- "name, address, or phone fields." End Literal Literal Text Line 1.500 Column .111 Value "When you press the OK button or type Ctrl/D, the "- "changes take effect for the rest of the session." End Literal Literal Text Line 1.750 Column .111 Value "However, these changes are not made permanently in the "- "Sample Application file. This " End Literal Literal Text Line 2.000 Column .111 Value "is how the sample was designed; DECforms does not "- "restrict you from making permanent " End Literal Literal Text Line 2.250 Column .111 Value "changes to any data base. To cancel changes at any "- "time and return to the choice panel, " End Literal Literal Text Line 2.500 Column .111 Value "press the Cancel button or type Ctrl/Q." End Literal Literal Text Line 3.000 Column .111 Value 'HINT: The password is "DECforms"' End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel CASH_PANEL_HELP Viewport HELP_VP Display Viewport Title "Cash Withdrawal Help" Display LABEL_ATTR Remove Literal Text Line .500 Column .333 Value "The cash choice allows you to pretend you are "- "withdrawing certain amounts of cash from" End Literal Literal Text Line .750 Column .333 Value "the checking account. Select an amount from the menu. "- "You will see a message telling" End Literal Literal Text Line 1.000 Column .333 Value "you that the cash was withdrawn and the amount in the "- "balance panel will be updated" End Literal Literal Text Line 1.250 Column .333 Value "accordingly. Select Cancel or type Ctrl/Q to return to "- "the main menu." End Literal Literal Text Line 2.000 Column .333 Value "Unfortunately, DECforms cannot supply you with the "- "actual cash. It is a good " End Literal Literal Text Line 2.250 Column .333 Value "product but it is not quite" End Literal Literal Text Line 2.255 Column 2.050 Value "that" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 2.250 Column 2.400 Value "good!" End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel CHECK_PANEL_HELP Viewport HELP_VP Display Viewport Title "Write A Check Help" Display LABEL_ATTR Remove Literal Text Line .250 Column .222 Value "You can write checks for amounts up to your current "- "balance, which is displayed in the" End Literal Literal Text Line .500 Column .222 Value "main panel. Fill in the payee, the amount to pay and "- "if you like, what the check is for." End Literal Literal Text Line .750 Column .222 Value "The amount will be accepted if it is covered by the "- "balance. The payee and memo will" End Literal Literal Text Line 1.000 Column .222 Value "always be accepted. After you are satisfied with the "- "contents of the check, press the" End Literal Literal Text Line 1.250 Column .222 Value "OK button or type Ctrl/D." End Literal Literal Text Line 1.750 Column .222 Value "The check is recorded in your check register, and the "- "checking balance is updated. To" End Literal Literal Text Line 2.000 Column .222 Value "print a copy of the check press Ctrl/P on the "- "keyboard. To cancel the check-writing" End Literal Literal Text Line 2.250 Column .222 Value "operation, press the Cancel button or type Ctrl/Q." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel CHOICE_PANEL_HELP Viewport HELP_VP Display Viewport Title "Personal Checking Account Help" Display LABEL_ATTR Remove Literal Text Line .250 Column .111 Value "The DECforms Checking Application simulates some "- "functions of electronic banking. " End Literal Literal Text Line .500 Column .111 Value "You can make deposits, write checks, make cash "- "withdrawals, transfer " End Literal Literal Text Line .750 Column .111 Value 'funds, and review account information. Your account at '- 'this "bank" has already ' End Literal Literal Text Line 1.000 Column .111 Value "been set up. You have made several deposits, and you "- "have written some checks. " End Literal Literal Text Line 1.250 Column .111 Value "You can choose the following functions by selecting "- "with the mouse and pressing MB1" End Literal Literal Text Line 1.500 Column .111 Value "or by using the arrow keys and typing the space or "- "Return keys. In addition, you can" End Literal Literal Text Line 1.750 Column .111 Value "select any function by an accelerator: ALT+first "- "letter of the command." End Literal Literal Text Line 2.250 Column .222 Value "Exit" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 2.250 Column 1.700 Value "Exits from the Sample Checking Application." End Literal Literal Text Line 2.500 Column .222 Value "Write a check" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 2.500 Column 1.700 Value "Displays a check. You type the payee, the amount, and "- "a memo." End Literal Literal Text Line 2.750 Column .222 Value "Deposit" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 2.750 Column 1.700 Value "Displays a deposit slip. You type the amount and a memo." End Literal Literal Text Line 3.000 Column .222 Value "Cash" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 3.000 Column 1.700 Value "Displays a menu. You select an amount of cash to "- "withdraw." End Literal Literal Text Line 3.250 Column .222 Value "Transfer" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 3.250 Column 1.700 Value "Displays a menu. You transfer between checking and "- "savings." End Literal Literal Text Line 3.500 Column .222 Value "Review" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 3.500 Column 1.700 Value "Displays a menu. You choose check register or account "- "info." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel DEPOSIT_PANEL_HELP Viewport HELP_VP Display Viewport Title "Deposit Record Help" Display LABEL_ATTR Remove Literal Text Line .500 Column .222 Value "To make a deposit, you enter the amount of the deposit "- "and, if you wish, a record" End Literal Literal Text Line .750 Column .222 Value "of where you got the money." End Literal Literal Text Line 1.250 Column .222 Value "After entering the amount, select the memo field to "- "enter the memo information." End Literal Literal Text Line 1.500 Column .222 Value "When you are satisfied with both fields, press the OK "- "button or type Ctrl/D to enter" End Literal Literal Text Line 1.750 Column .222 Value "the deposit. To cancel the deposit at any time and "- "return to the choice panel," End Literal Literal Text Line 2.000 Column .222 Value "press the Cancel button or type Ctrl/Q." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel REGISTER_PANEL_HELP Viewport HELP_VP Display Viewport Title "Register Help" Display LABEL_ATTR Remove Literal Text Line .250 Column .222 Value "The register consists of several banking entries. You "- "can read through the " End Literal Literal Text Line .500 Column .222 Value "register list by using the scroll bar, up & down "- "arrows, or (to travel to the next page)" End Literal Literal Text Line .750 Column .222 Value "Previous Panel (Shift/PF3) & Next Panel (Shift/PF4)." End Literal Literal Text Line 1.250 Column .222 Value 'The only information you can change in this panel is '- 'the "Tax Deduction" column; it can be ' End Literal Literal Text Line 1.500 Column .222 Value "either 0 or 1. Return to the choice panel by pressing "- "the OK button or typing Ctrl/D" End Literal Literal Text Line 1.750 Column .222 Value "(to record changes). Press the Cancel button or type "- "Ctrl/Q to cancel any changes." End Literal Literal Text Line 2.250 Column .222 Value "The sample application is designed to handle only 30 "- "register entries; this limit" End Literal Literal Text Line 2.500 Column .222 Value "is not a restriction of DECforms but of the "- "application. When the limit " End Literal Literal Text Line 2.750 Column .222 Value "has been reached, the form does not allow you to "- "choose any of the first " End Literal Literal Text Line 3.000 Column .222 Value "four options on the choice panel, since they all "- "result in register entries." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel REVIEW_PANEL_HELP Viewport HELP_VP Display Viewport Title "Review Help" Display LABEL_ATTR Remove Literal Text Line .500 Column .555 Value "To review the check register, select" End Literal Literal Text Line .500 Column 2.900 Value "Review Register." Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 1.000 Column .555 Value "To review the personal information for the account, "- "select" End Literal Literal Text Line 1.000 Column 4.350 Value "Review Account." Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 1.500 Column .555 Value "Select Cancel or type Ctrl/D to return to the main menu." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel TRANSFER_PANEL_HELP Viewport HELP_VP Display Viewport Title "Transfer Funds Help" Display LABEL_ATTR Remove Literal Text Line .500 Column .333 Value "To transfer funds from checking into savings, select" End Literal Literal Text Line .500 Column 3.750 Value "From checking to savings." Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line .750 Column .333 Value "To transfer funds from savings into checking, select" End Literal Literal Text Line .750 Column 3.750 Value "From savings to checking." Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 1.250 Column .333 Value "Specify the amount to be transferred in the amount "- "field. Press the OK button" End Literal Literal Text Line 1.500 Column .333 Value "or type Ctrl/D to enter the transfer; press the Cancel "- "button or type Ctrl/Q to cancel it." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .500 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel Help Panel WELCOME_PANEL_HELP Viewport HELP_VP Display Viewport Title "DECforms Demo Help" Display LABEL_ATTR Remove Literal Text Line .250 Column .222 Value "The Sample Checking Application shows how to use "- "DECforms." End Literal Literal Text Line .750 Column .222 Value "The documentation cites many examples from the "- "Checking Application." End Literal Literal Text Line 1.000 Column .222 Value "This application does not claim to show the" End Literal Literal Text Line 1.000 Column 3.100 Value "best" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 1.000 Column 3.460 Value "way of doing everything." End Literal Literal Text Line 1.250 Column .222 Value "Rather, it shows ways that things" End Literal Literal Text Line 1.250 Column 2.530 Value "can" Display Font Weight Bold LABEL_ATTR End Literal Literal Text Line 1.250 Column 2.810 Value "be done with DECforms." End Literal Literal Text Line 1.750 Column .222 Value "As you run the rest of the application, you can get "- "help by pressing the HELP button or " End Literal Literal Text Line 2.000 Column .222 Value "typing the HELP KEY. You may cancel any operation by "- "pressing the Cancel button." End Literal Literal Text Line 2.250 Column .222 Value "or by typing Ctrl/Q. To execute any checking "- "operations press the OK button or type Ctrl/D." End Literal Push Button DISMISS_HELP_BUTTON Line 3.700 Column 4.500 Height .550 Width 1.500 Function Response TRIGGER OBJECT Exit Help End Response Display BUTTON_LABEL_ATTR Label "Dismiss" End Button End Panel End Layout End Form