IMD 1.16: 29/05/2007 18:50:26 FOGCPM.078 --FOGCPM078LOADER CMDMAIL DOC MAILCOMPNDXMAILREP CMD MAILZIP NDX MAINMENUFMT MAKEMEM CMDPOSTCARDFMT PRELUDE CMDPRINTLBLCMDPRINTOFFCMDPRINTREPCMDREP FMT SEARCH CMDSELECTMNFMT UP1LBL CMDUP1SEL CMD UP2LBL CMD !UP2SEL CMD"#$UP3LBL CMD %&UP3SEL CMD'()UPDATE CMD*UPDATEMNFMT +,ADD MEM-./ALPH FRM0APEXMAILDBF 12CARDS CMD 34DUMP FRM5HELLO CMD6LABELMENFMT 78LABELS CMD9DSCREEN CMD:;<=>?@ABCDEFGHIDSCREEN CMDJKL-06-00 86 DSCREEN DOCMNOPQRSTUVWXYZ[\DSCREEN DOC]^_`abcdefghijklDSCREEN DOC(mnopq-CPM078 DOCDSCREEN 23Brstuvwxyz{|}~DSCREEN 23BMETALENTCMD5METALS DBFMETALS DBS$TEST DBFTEST DBS TESTENT CMD$XSCREEN DBFThis is the disk name. MAILZIP NDX MAINMENUFMT MAKEMEM CMDPOSTCARDFMT PRELUDE CMDPRINTLBLCMDPRINTOFFCMDPRINTREPCMDREP FMT SEARCH CMDSELECTMNFMT UP1LBL CMDUP1SEL CMD UP2LBL CMD  UP2SEL CMD!"#UP3LBL CMD $%UP3SEL CMD&'(UPDATE CMD)UPDATEMNFMT *+ADD MEM,-.ALPH FRM/APEXMAILDBF 01CARDS CMD 23DUMP FRM4HELLO CMD5LABELMENFMT 67LABELS CMD8DSCREEN CMD9:;<=>?@ABCDEFGH* LOADER.CMD SET INTENSITY OFF ERASE SET DEFAULT TO B: DO HELLO MAILZIP NDX MAINMENUFMT MAKEMEM CMDPOSTCARDFMT PRELUDE CMDPRINTLBLCMDPRINTOFFCMDPRINTREPCMDREP FMT SEARCH CMDSELECTMNFMT UP1LBL CMDUP1SEL CMD UP2LBL CMD  UP2SEL CMD!"#UP3LBL CMD $%UP3SEL CMD&'(UPDATE CMD)UPDATEMNFMT *+ADD MEM,-.ALPH FRM/APEXMAILDBF 01CARDS CMD 23DUMP FRM4HELLO CMD5LABELMENFMT 67LABELS CMD8DSCREEN CMD9:;<=>?@ABCDEFGH APEX TOOLWORKS MAILING LIST SYSTEM This package of dBase II programs was created as a senior project in software development. Since I had not worked with dBase II before, there may be ways to do some of the functions of the mail manager in a more efficient way, but I will leave that to the user. The database "APEXMAIL.DBF" has a number of entries already. Make sure you don't destroy the structure of the database file if you create your own file. NOTE: THE MANUAL FOR THIS SOFTWARE PACKAGE IS IN THE POSSESSION OF THE DEFOG USER GROUP AND MAY BE MADE AVAILABLE FOR COPIES. YOU MAY COMPLETELY DIS- REGARD ANY COPYRIGHT NOTICES ON THE MANUAL FOR THE FOLLOWING REASONS: 1. There is no such company: Apex Toolworks. 2. There is no such company: On-Target. 3. As the true copyright holder of the software, I grant full use of the mailing list manual and software to any individual or group, for any purpose. If I can help you implement the package, or you just have some questions, call Randy Shafer 332-5124 Weekends only please.  help you implement the packagvelopment. Since I had not worked with dBase II before, there may be ways to do some of the functions of the mail manager in a more efficient way, but I will leave that to the user. The database "APEXMAIL.DBF" has a number of entries already. Make sure you don't destroy the structure of the database file if you create your own file. NOTE: THE MANUAL FOR THIS SOFTWARE PACKAGE IS IN THE POSSESSION OF THE DEFOG USER GROUP AND MAY BE MADE AVAILABLE FOR COPIES. YOU MAY COMPLETELY DIS- REGARD ANY COPYRIGHT NOTICES ON THE MANUAL FOR THE FOLLOWING REASONS: 1. There is no such company: Apex Toolworks. 2. There is no such company: On-Target. 3. As the true copyright holder of the software, I grant full use of the mailing list manual and software to any individual or group, for any purpose. If I can help you implement the packag"$COMPANYY) NATIONAL MACHINERY COMPANY WASINO CORPORATION USA (RAYTHEON LASER CENTER %ROHM TOOL CORPORATION %ROHM TOOL CORPORATION %ROHM TOOL CORPORATION SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. ANILAM ELECTRONICS CORPORATION WALTER WASINO CORPORATION USA WESTINGHOUSE ELECTRIC CORP. WESTINGHOUSE ELECTRIC- UNIMATIONWHITE CONSOLIDATED INDUSTRIES SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. WESTINGHOUSE ELECTRIC- UNIMATION WHITE CONSOLIDATED INDUSTRIES WHINATIONAL MACHINERY COMPANY WASINO CORPORATION USA (RAYTHEON LASER CENTER %ROHM TOOL CORPORATION %ROHM TOOL CORPORATION %ROHM TOOL CORPORATION SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. WESTINGHOUSE ELECTRIC- UNIMATION WHITE CONSOLIDATED INDUSTRIES WHINATIONAL MACHINERY COMPANY NATIONAL MACHINERY COMPANY NATIONAL MACHINERY COMPANY STARRETT INDUSTRIAL SUPPLY CO. THE OLOFSSON CORPORATION WESTINGHOUSE ELECTRIC- UNIMATION WHITE-SUNSTRAND MACHINE TOOL CO. MACHINE INTELLIGENCE CORPORATIONMORSE CUTTING TOOLS NATIONAL MACHINERY COMPANY NIKON VISIONS, NIKON INC. STARRETT INDUSTRIAL SUPPLY CO. THE OLOFSSON CORPORATION WESTINGHOUSE ELECTRIC- UNIMATION WHI)HURCO MANUFACTURING CO., INC. )HURCO MANUFACTURING CO., INC. KTS INDUSTRIES, INCORPORATED KTS INDUSTRIES, INCORPORATED KTS INDUSTRIES, INCORPORATED KTS INDUSTRIES, INCORPORATED KTS INDUSTRIES, INCORPORATED MACHINE INTELLIGENCE CORPORATION MACHINE INTELLIGENCE CORPORATION MACHINE INTELLIGENCE CORPORATIONHANLO GAUGE HARDINGE BROTHERS, INC. INGERSOLL CUTTING TOOL COMPANY ISCAR METALS INCORPORATED MAC -SKF & DORMER TOOLS CORPORATION ,SUMIDEN CARBIDE AMERICA, INC. *W.A. WHITNEY WALTER .WASINO CORPORATION USA WESTINGHOUSE ELECTRIC CORP. WESTINGHOUSE ELECTRIC- UNIMATIONWHITE CONSOLIDATED INDUSTRIES WHITE-SUNSTRAND MACHINE TOOL CO.WHITE-SUNSTRAND MACHINE TOOL CO.WHITE-SUNSTRAND MACHINE TOOL CO. WHITE-SUNSTRAND MACHINE TOOL CO. WHITE-SUNSTRAND MACHINE TOOL CO. WHITE CONSOLIDATED INDUSTRIES WHI* MAILREP.CMD SET TALK OFF RELEASE ALL USE APEXMAIL INDEX MAILCOMP STORE " " TO ANSWER DO PRINTREP DO WHILE T ERASE SET FORMAT TO REP READ SET CONSOLE OFF DO CASE CASE ANSWER = "1" SET HEADING TO APEX TOOLWORKS- MAILING LIST REPORT BY COMPANY NAME REPORT FORM DUMP TO PRINT CASE ANSWER = "2" USE APEXMAIL INDEX MAILZIP SET HEADING TO APEX TOOLWORKS- MAILING LIST REPORT BY ZIP CODE REPORT FORM DUMP TO PRINT USE APEXMAIL INDEX MAILCOMP CASE ANSWER = "3" SET HEADING TO APEX TOOLWORKS- MAILING LIST REPORT FOR GROUP "A" REPORT FORM DUMP TO PRINT FOR GROUP = "A" CASE ANSWER = "4" SET HEADING TO APEX TOOLWORKS- MAILING LIST REPORT FOR GROUP "B" REPORT FORM DUMP TO PRINT FOR GROUP = "B" CASE ANSWER = "5" SET HEADING TO APEX TOOLWORKS- MAILING LIST REPORT FOR GROUP "C" REPORT FORM DUMP TO PRINT FOR GROUP = "C" CASE ANSWER = "6" SET HEADING TO APEX TOOLWORKS- MAILING LIST REPORT FOR GROUP "D" REPORT FORM DUMP TO PRINT FOR GROUP = "D" CASE ANSWER = "7" SET HEADING TO APEX TOOLWORKS- MAILING LIST REPORT FOR GROUP "E" REPORT FORM DUMP TO PRINT FOR GROUP = "E" CASE ANSWER = "8" SET CONSOLE ON DO PRINTOFF RETURN ENDCASE STORE " " TO ANSWER ENDDO  "E" CASE ANSWER = "8" SET CONSOLE ON RETURN ENDCASE STORE " " TO ANSWER ENDDO  CASE ANSWER = "3" SET HEADING TO APEX TOOLWORKS- MAILING LIST REPORT FOR GROUP "A" REPORT FORM DUMP TO PRINT FOR GROUP = "A" CASE ANSWER = "4" SET HEADING TO APEX TOOLWORKS- MAILING LIST REPORT FOR GROUP "B" REPORT FORM DUMP TO PRINT FOR GROUP = "B" CASE ANSWER = "5" SET HEADING TO APEX TOOLWORKS- MAILING LIST REPORT FOR GROUP "C" REPORT FORM DUMP TO PRINT FOR GROUP = "C" CASE ANSWER = "6" SET HEADING TO APEX TOOLWORKS- MAILING LIST REP $ZIPANYY) ANILAM ELECTRONICS CORPORATION WALTER WASINO CORPORATION USA WESTINGHOUSE ELECTRIC CORP. WESTINGHOUSE ELECTRIC- UNIMATIONWHITE CONSOLIDATED INDUSTRIES SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. 06609 11788 15205 15221 22403 33166 PORATION USA WESTINGHOUSE ELECTRIC CORP. WESTINGHOUSE ELECTRIC- UNIMATIONWHITE CONSOLIDATED INDUSTRIES SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. SHAFER CONSULTANTS, INC. WESTINGHOUSE ELECTRIC- UNIMATION WHITE CONSOLIDATED INDUSTRIES WHI48058 48059 48068 48090 '48106 48160 48909 49007 55041 60007 "60048 ,60056 60521 60566 60638 61008 61008 61103 *61105 77251 92680 94545 48090 48160 48909 49007 55041 60007 "60048 60521 60566 60638 61008 61103 77251 92680 945$48043-028748059 48068 48090 48160 48909 49007 55041 60007 "60048 60521 60566 60638 61008 61103 77251 92680 94545 48057 48058 48059 48068 48090 48160 48909 49007 55041 60007 "60048 60521 60566 60638 61008 61103 77251 92680 945 * MAINMENU.FMT @ 1, 0 SAY "+-------------------------------------------------" @ 1,50 SAY "-+" @ 2, 0 SAY "| APEX TOOLWORKS INC." @ 2,51 SAY "|" @ 3, 0 SAY "| Mailing List Management System." @ 3,51 SAY "|" @ 4, 0 SAY "+-------------------------------------------------" @ 4,50 SAY "-+" @ 5, 0 SAY "| Select one of the following options by number-" @ 5,51 SAY "|" @ 6, 0 SAY "|" @ 6,51 SAY "|" @ 7, 0 SAY "| 1. Update or view the mail list." @ 7,51 SAY "|" @ 8, 0 SAY "|" @ 8,51 SAY "|" @ 9, 0 SAY "| 2. Print a report of the mail list contents." @ 9,51 SAY "|" @ 10, 0 SAY "|" @ 10,51 SAY "|" @ 11, 0 SAY "| 3. Print mail labels." @ 11,51 SAY "|" @ 12, 0 SAY "|" @ 12,51 SAY "|" @ 13, 0 SAY "| 4. Print post cards." @ 13,51 SAY "|" @ 14, 0 SAY "|" @ 14,51 SAY "|" @ 15, 0 SAY "| 5. Exit the mail manager and enter dBase II" @ 15,51 SAY "|" @ 16, 0 SAY "| language." @ 16,51 SAY "|" @ 17, 0 SAY "|" @ 17,51 SAY "|" @ 18, 0 SAY "| 6. Exit the mail manager and enter CP/M." @ 18,51 SAY "|" @ 19, 0 SAY "|" @ 19,51 SAY "|" @ 20, 0 SAY "| Which item number do you want?" @ 20,33 GET answer @ 20,51 SAY "|" @ 21, 0 SAY "| MAINMENU" @ 21,51 SAY "|" @ 22, 0 SAY "+-------------------------------------------------" @ 22,50 SAY "-+"ber-" @ 5,51 SAY "|" @ 6, 0 SAY "|" @ 6,51 SAY "|" @ 7, 0 SAY "| 1. Update or view the mail list." @ 7,51 SAY "|" @ 8, 0 SAY "|" @ 8,51 SAY "|" @ 9, 0 SAY "| 2. Print a report of the mail list contents." @ 9,51 SAY "|" @ 10, 0 SAY "|" @ 10,51 SAY "|" @ 11, 0 SAY "| 3. Print mail labels." @ 11,51 SAY "|" @ 12, 0 SAY "|" @ 12,51 SAY "|" @ 13, 0 SAY "| 4. Print post cards." @ 13,51 SAY "|" @ 14, 0 SAY "|" @ 14,51 SAY "|" @ 15, 0 SAY "| 5. Exit the mail manager and enter dBase II" @ 15,51 SAY "|" @ 16, 0 SAY "| language." @ 16,51 SAY "|" @ 17, 0 SAY "|" @ 17,51 SAY "|" @ 18, 0 SAY "| 6* MAKEMEM.CMD STORE " " TO COMPNAME STORE " " TO ADDR1 STORE " " TO ADDR2 STORE " " TO ATTN STORE " " TO CT STORE " " TO ST STORE " " TO ZP STORE " " TO GRP SAVE TO ADD RELEASE ALL RETURN REP FMT SEARCH CMDSELECTMNFMT UP1LBL CMDUP1SEL CMD UP2LBL CMD  UP2SEL CMD!"#UP3LBL CMD $%UP3SEL CMD&'(UPDATE CMD)UPDATEMNFMT *+ADD MEM,-.ALPH FRM/APEXMAILDBF 01CARDS CMD 23DUMP FRM4HELLO CMD5LABELMENFMT 67LABELS CMD8DSCREEN CMD9:;<=>?@ABCDEFGH * POSTCARD.FMT @ 1, 0 SAY "+=================================================" @ 1,50 SAY "=+" @ 2, 0 SAY "| APEX TOOLWORKS- General Mailing List Manager." @ 2,51 SAY "|" @ 3, 0 SAY "+=================================================" @ 3,50 SAY "=+" @ 4, 0 SAY "| You may type any text into the lines provided." @ 4,51 SAY "|" @ 5, 0 SAY "| The text will appear on the front of the card" @ 5,51 SAY "|" @ 6, 0 SAY "| areas allowed for text by the U.S. Postal Svc." @ 6,51 SAY "|" @ 7, 0 SAY "|" @ 7,51 SAY "|" @ 8, 0 SAY "|" @ 8, 3 GET line1 @ 8,49 SAY "+ |" @ 9, 0 SAY "|" @ 9, 3 GET line2 @ 9,49 SAY "+ |" @ 10, 0 SAY "|" @ 10, 3 GET line3 @ 10,49 SAY "+ |" @ 11, 0 SAY "|" @ 11, 3 GET line4 @ 11,49 SAY "+ |" @ 12, 0 SAY "|" @ 12, 3 GET line5 @ 12,49 SAY "+ |" @ 13, 0 SAY "|" @ 13, 3 GET line6 @ 13,27 SAY "+ |" @ 14, 0 SAY "|" @ 14, 3 GET line7 @ 14,27 SAY "+ |" @ 15, 0 SAY "|" @ 15, 3 GET line8 @ 15,27 SAY "+  |" @ 16, 0 SAY "|" @ 16, 3 GET line9 @ 16,27 SAY "+ |" @ 17, 0 SAY "|" @ 17, 3 GET line10 @ 17,27 SAY "+ |" @ 18, 0 SAY "|" @ 18, 3 GET line11 @ 18,27 SAY "+ |" @ 19, 0 SAY "|" @ 19, 3 GET line12 @ 19,27 SAY "+ |" @ 20, 0 SAY "|" @ 20, 3 GET line13 @ 20,27 SAY "+ |" @ 21, 0 SAY "|" @ 21, 3 GET line14 @ 21,27 SAY "+ |" @ 22, 0 SAY "+=================================================" @ 22,50 SAY "=+"49 SAY "+ |" @ 10, 0 SAY "|" @ 10, 3 GET line3 @ 10,49 SAY "+ |" @ 11, 0 SAY "|" @ 11, 3 GET line4 @ 11,49 SAY "+ |" @ 12, 0 SAY "|" @ 12, 3 GET line5 @ 12,49 SAY "+ |" @ 13, 0 SAY "|" @ 13, 3 GET line6 @ 13,27 SAY "+ |" @ 14, 0 SAY "|" @ 14, 3 GET line7 @ 14,27 SAY "+ |" @ 15, 0 SAY "|" @ 15, 3 GET line8 @ 15,27 SAY "+  * PRELUDE.CMD ERASE @ 1, 0 SAY "+=================================================" @ 1,50 SAY "=+" @ 2, 0 SAY "|" @ 2,51 SAY "|" @ 3, 0 SAY "| A P E X T O O L W O R K S I N C ." @ 3,51 SAY "|" @ 4, 0 SAY "|" @ 4,51 SAY "|" @ 5, 0 SAY "| GENERAL MAILING LIST" @ 5,51 SAY "|" @ 6, 0 SAY "| MANAGER" @ 6,51 SAY "|" @ 7, 0 SAY "|" @ 7,51 SAY "|" @ 8, 0 SAY "+=================================================" @ 8,50 SAY "=+" @ 9, 0 SAY "|" @ 9,51 SAY "|" @ 10, 0 SAY "|" @ 10,51 SAY "|" @ 11, 0 SAY "| THE SYSTEM INDEX FILES ARE BEING UPDATED" @ 11,51 SAY "|" @ 12, 0 SAY "|" @ 12,51 SAY "|" @ 13, 0 SAY "|" @ 13,51 SAY "|" @ 14, 0 SAY "|" @ 14,51 SAY "|" @ 15, 0 SAY "| PLEASE BE PATIENT" @ 15,51 SAY "|" @ 16, 0 SAY "|" @ 16,51 SAY "|" @ 17, 0 SAY "|" @ 17,51 SAY "|" @ 18, 0 SAY "|" @ 18,51 SAY "|" @ 19, 0 SAY "| THANK YOU !" @ 19,51 SAY "|" @ 20, 0 SAY "|" @ 20,51 SAY "|" @ 21, 0 SAY "|" @ 21,51 SAY "|" @ 22, 0 SAY "+=================================================" RETURN O MAILCOMP INDEX ON ZIP TO MAILZIP RETURN +-------------------------------------------------" @ 4,50 SAY "-+" @ 5, 0 SAY "| Select one of the following options by number-" @ 5,51 SAY "|" @ 6, 0 SAY "|" @ 6,51 SAY "|" @ 7, 0 SAY "| 1. Update or view the mail list." @ 7,51 SAY "|" @* PRELUDE.CMD ERASE @ 1, 0 SAY "+=================================================" @ 1,50 SAY "=+" @ 2, 0 SAY "|" @ 2,51 SAY "|" @ 3, 0 SAY "| A P E X T O O L W O R K S I N C ." @ 3,51 SAY "|" @ 4, 0 SAY "|" @ 4,51 SAY "|" @ 5, 0 SAY "| GENERAL MAILING LIST" @ 5,51 SAY "|" @ 6, 0 SAY "| MANAGER" @ 6,51 SAY "|" @ 7, 0 SAY "|" @ 7,51 SAY "|" @ 8, 0 SAY "+=================================================" @ 8,50 SAY "=+" @ 9, 0 SAYSET PRINT ON SET CONSOLE OFF ? CHR(27) + CHR(69) SET PRINT OFF RETURN MAILREP CMD MAILZIP NDX MAINMENUFMT MAKEMEM CMDPOSTCARDFMT PRELUDE CMDPRINTLBL$$$PRINTREPCMDREP FMT SEARCH CMDSELECTMNFMT UP1LBL CMDUP1SEL CMD UP2LBL CMD  UP2SEL CMD!"#UP3LBL CMD $%UP3SEL CMD&'(UPDATE CMD)UPDATEMNFMT *+ADD MEM,-.ALPH FRM/APEXMAILDBF 01CARDS CMD 23DUMP FRM4HELLO CMD5LABELMENFMT 67LABELS CMD8DSCREEN CMD9:;<=>?@ABCDEFGHSET CONSOLE OFF SET PRINT ON ? CHR(27) + CHR(70) ? CHR(18) SET PRINT OFF SET CONSOLE ON RETURN MAILREP CMD MAILZIP NDX MAINMENUFMT MAKEMEM CMDPOSTCARDFMT PRELUDE CMDPRINTLBLCMDPRINTOFF$$$REP FMT SEARCH CMDSELECTMNFMT UP1LBL CMDUP1SEL CMD UP2LBL CMD  UP2SEL CMD!"#UP3LBL CMD $%UP3SEL CMD&'(UPDATE CMD)UPDATEMNFMT *+ADD MEM,-.ALPH FRM/APEXMAILDBF 01CARDS CMD 23DUMP FRM4HELLO CMD5LABELMENFMT 67LABELS CMD8DSCREEN CMD9:;<=>?@ABCDEFGHSET PRINT ON ? CHR(15) SET PRINT OFF RETURN MAILREP CMD MAILZIP NDX MAINMENUFMT MAKEMEM CMDPOSTCARDFMT PRELUDE CMDPRINTLBLCMDPRINTOFFCMDPRINTREP$$$SEARCH CMDSELECTMNFMT UP1LBL CMDUP1SEL CMD UP2LBL CMD  UP2SEL CMD!"#UP3LBL CMD $%UP3SEL CMD&'(UPDATE CMD)UPDATEMNFMT *+ADD MEM,-.ALPH FRM/APEXMAILDBF 01CARDS CMD 23DUMP FRM4HELLO CMD5LABELMENFMT 67LABELS CMD8DSCREEN CMD9:;<=>?@ABCDEFGH * REP.FMT @ 1, 0 SAY "+-------------------------------------------------" @ 1,50 SAY "-+" @ 2, 0 SAY "| APEX TOOLWORKS- General Mailing List Manager." @ 2,51 SAY "|" @ 3, 0 SAY "+-------------------------------------------------" @ 3,50 SAY "-+" @ 4, 0 SAY "| REPORT FORM SELECTION" @ 4,51 SAY "|" @ 5, 0 SAY "|" @ 5,51 SAY "|" @ 6, 0 SAY "| Choose an option by number-" @ 6,51 SAY "|" @ 7, 0 SAY "|" @ 7,51 SAY "|" @ 8, 0 SAY "|" @ 8,51 SAY "|" @ 9, 0 SAY "| 1) All mail entries sorted by company." @ 9,51 SAY "|" @ 10, 0 SAY "| 2) All mail entries sorted by zip code." @ 10,51 SAY "|" @ 11, 0 SAY "| 3) Group A companies only." @ 11,51 SAY "|" @ 12, 0 SAY "| 4) Group B companies only." @ 12,51 SAY "|" @ 13, 0 SAY "| 5) Group C companies only." @ 13,51 SAY "|" @ 14, 0 SAY "| 6) Group D companies only." @ 14,51 SAY "|" @ 15, 0 SAY "| 7) Group E companies only." @ 15,51 SAY "|" @ 16, 0 SAY "|" @ 16,51 SAY "|" @ 17, 0 SAY "| 8) RETURN to the main menu." @ 17,51 SAY "|" @ 18, 0 SAY "|" @ 18,51 SAY "|" @ 19, 0 SAY "|" @ 19,51 SAY "|" @ 20, 0 SAY "| What is your selection?" @ 20,26 GET answer @ 20,51 SAY "|" @ 21, 0 SAY "|" @ 21,51 SAY "|" @ 22, 0 SAY "+-------------------------------------------------" @ 22,50 SAY "-+"an option by number-" @ 6,51 SAY "|" @ 7, 0 SAY "|" @ 7,51 SAY "|" @ 8, 0 SAY "|" @ 8,51 SAY "|" @ 9, 0 SAY "| 1) All mail entries sorted by company." @ 9,51 SAY "|" @ 10, 0 SAY "| 2) All mail entries sorted by zip code." @ 10,51 SAY "|" @ 11, 0 SAY "| 3) Group A companies only." @ 11,51 SAY "|" @ 12, 0 SAY "| 4) Group B companies only." @ 12,51 SAY "|" @ 13, 0 SAY "| 5) Group C companies only." @ 13,51 SAY "|" @ 14, 0 SAY "| 6) Group D companies only." @ 14,51 SAY "|" @ 15, 0 SAY "| 7) Group E companies only." @ 15,51 SAY "|" @ 16, 0 SAY "|" @ 16,51 SAY "|" @ 17* SEARCH.CMD ERASE USE APEXMAIL INDEX MAILCOMP ? ? ? ? ? ACCEPT "Please enter the company name to search for" to NAME STORE !(NAME) TO NAME FIND &NAME IF # = 0 ERASE ? ? ? ? ? ? ? NAME , "is not in the file" ? "Hit any key to return to the menu." SET CONSOLE OFF WAIT SET CONSOLE ON ENDIF RELEASE NAME RETURN PRINTREPCMDREP FMT SEARCH $$$UP1LBL CMDUP1SEL CMD UP2LBL CMD  UP2SEL CMD!"#UP3LBL CMD $%UP3SEL CMD&'(UPDATE CMD)UPDATEMNFMT *+ADD MEM,-.ALPH FRM/APEXMAILDBF 01CARDS CMD 23DUMP FRM4HELLO CMD5LABELMENFMT 67LABELS CMD8DSCREEN CMD9:;<=>?@ABCDEFGH * SELECTMN.FMT @ 1, 0 SAY "+-------------------------------------------------" @ 1,50 SAY "-+" @ 2, 0 SAY "| APEX TOOLWORKS- General Mailing List Manager." @ 2,51 SAY "|" @ 3, 0 SAY "+-------------------------------------------------" @ 3,50 SAY "-+" @ 4, 0 SAY "|" @ 4,51 SAY "|" @ 5, 0 SAY "| MAIL LABEL PRINTOUT- GROUP SELECTION" @ 5,51 SAY "|" @ 6, 0 SAY "|" @ 6,51 SAY "|" @ 7, 0 SAY "| Place the group selection characters-" @ 7,51 SAY "|" @ 8, 0 SAY "| (A,B,C,D or E) in the order you want them" @ 8,51 SAY "|" @ 9, 0 SAY "| to be printed out. Since up to 6 passes" @ 9,51 SAY "|" @ 10, 0 SAY "| can be made and there are only 5 groups," @ 10,51 SAY "|" @ 11, 0 SAY "| multiple copies of a group can be made." @ 11,51 SAY "|" @ 12, 0 SAY "| Passes with blank group selection will be" @ 12,51 SAY "|" @ 13, 0 SAY "| skipped." @ 13,51 SAY "|" @ 14, 0 SAY "|" @ 14,51 SAY "|" @ 15, 0 SAY "| PASS 1" @ 15,11 GET pass1 @ 15,28 SAY "PASS 2" @ 15,35 GET pass2 @ 15,51 SAY "|" @ 16, 0 SAY "|" @ 16,51 SAY "|" @ 17, 0 SAY "| PASS 3" @ 17,11 GET pass3 @ 17,28 SAY "PASS 4" @ 17,35 GET pass4 @ 17,51 SAY "|" @ 18, 0 SAY "|" @ 18,51 SAY "|" @ 19, 0 SAY "| PASS 5" @ 19,11 GET pass5 @ 19,28 SAY "PASS 6" @ 19,35 GET pass6 @ 19,51 SAY "|" @ 20, 0 SAY "|" @ 20,51 SAY "|" @ 21, 0 SAY "| If all passes are blank, no print will occur." @ 21,51 SAY "|" @ 22, 0 SAY "+-------------------------------------------------" @ 22,50 SAY "-+" in the order you want them" @ 8,51 SAY "|" @ 9, 0 SAY "| to be printed out. Since up to 6 passes" @ 9,51 SAY "|" @ 10, 0 SAY "| can be made and there are only 5 groups," @ 10,51 SAY "|" @ 11, 0 SAY "| multiple copies of a group can be made." @ 11,51 SAY "|" @ 12, 0 SAY "| Passes with blank group selection will be" @ 12,51 SAY "|" @ 13, 0 SAY "| skipped." @ 13,51 SAY "|" @ 14, 0 SAY "|" @ 14,51 SAY "|" @ 15, 0 SAY "| PASS 1" @ 15,11 GET pass1 @ 15,28 SAY "PASS 2" @ 15,35 GETUSE APEXMAIL INDEX MAILZIP GO TOP SET TALK OFF SET CONSOLE OFF DO PRINTLBL SET PRINT ON DO WHILE .NOT. EOF ? ATTENTION ? COMPANY ? ADDRESS1 ? ADDRESS2 ? TRIM(CITY) + ", " + STATE + " " + ZIP ? SKIP ENDDO GO TOP SET PRINT OFF DO PRINTOFF SET RAW ON SET TALK ON SET CONSOLE ON RETURN PRINTREPCMDREP FMT SEARCH CMDSELECTMNFMT UP1LBL $$$UP2LBL CMD  UP2SEL CMD!"#UP3LBL CMD $%UP3SEL CMD&'(UPDATE CMD)UPDATEMNFMT *+ADD MEM,-.ALPH FRM/APEXMAILDBF 01CARDS CMD 23DUMP FRM4HELLO CMD5LABELMENFMT 67LABELS CMD8DSCREEN CMD9:;<=>?@ABCDEFGH * UP1SEL.CMD USE APEXMAIL INDEX MAILZIP STORE " " TO PASS1 STORE " " TO PASS2 STORE " " TO PASS3 STORE " " TO PASS4 STORE " " TO PASS5 STORE " " TO PASS6 STORE " " TO HOLDER STORE 1 TO COUNTER SET FORMAT TO SELECTMN READ SET CONSOLE OFF SET TALK OFF SET RAW ON DO PRINTLBL SET PRINT ON IF PASS1 = " " .AND. PASS2 = " " .AND. PASS3 = " " .AND. PASS4 = " "; .AND. PASS5 = " " .AND. PASS6 = " " SET TALK ON SET CONSOLE ON DO PRINTOFF SET PRINT OFF SET RAW OFF RETURN ENDIF DO WHILE COUNTER < 7 DO CASE CASE COUNTER = 1 STORE PASS1 TO HOLDER CASE COUNTER = 2 STORE PASS2 TO HOLDER CASE COUNTER = 3 STORE PASS3 TO HOLDER CASE COUNTER = 4 STORE PASS4 TO HOLDER CASE COUNTER = 5 STORE PASS5 TO HOLDER CASE COUNTER = 6 STORE PASS6 TO HOLDER ENDCASE IF HOLDER <> " " DO WHILE .NOT. EOF IF GROUP = HOLDER ? ATTENTION ? COMPANY ? ADDRESS1 ? ADDRESS2 ? TRIM(CITY) + ", " + STATE + " " + ZIP ? ENDIF SKIP ENDDO ENDIF STORE COUNTER + 1 TO COUNTER STORE " " TO HOLDER GO TOP ENDDO SET PRINT OFF DO PRINTOFF SET RAW ON SET TALK ON SET CONSOLE ON RETURN " " TO PASS5 STORE " " TO PASS6 STORE " " TO HOLDER STORE 1 TO COUNTER SET FORMAT TO SELECTMN READ SET CONSOLE OFF SET TALK OFF SET RAW ON DO PRINTLBL SET PRINT ON IF PASS1 = " " .AND. PASS2 = " " .AND. PASS3 = " " .AND. PASS4 = " "; .AND. PASS5 = " " .AND. PASS6 = " " SET TALK ON SET CONSOLE ON DO PRINTOFF SET PRINT OFF SET RAW OFF RETURN ENDIF DO WHILE COUNTER < 7 DO CASE CASE COUNTER = 1 STORE PASS1 TO HOLDER CASE COUNTER = 2 STORE PASS2 TO HOLDER CASE COUNTER = 3 STORE PASS3 TO HOLDER CASE COUNTER = 4 STORE PASS4 TO HOLDER CASE COUNTER = 5 STORE PASS5 TO HOLDER CASE COUNTER = 6 STORE PASS6 TO HOLDER ENDCASE IF HOLDER <> " " DO WHILE .NOT. EOF IF GROUP = HOLDER ? ATTENTION ? COMPANY ? ADDRESS1 ? ADDRESS2 ? TRIM(CITY) + ", " + STATE + " " + ZIP ? ENDIF SKIP ENDDO ENDIF STORE COUNTER + 1 TO COUNTER STORE " " TO HOLDER GO TOP USE APEXMAIL INDEX MAILZIP SET CONSOLE OFF SET TALK OFF SET RAW ON GO TOP STORE T TO GO DO WHILE GO STORE " " TO AT1 STORE " " TO AT2 STORE " " TO NAME1 STORE " " TO NAME2 STORE " " TO ADR1A STORE " " TO ADR1B STORE " " TO ADR2A STORE " " TO ADR2B STORE " " TO LAST1 STORE " " TO LAST2 IF .NOT. EOF STORE ATTENTION TO AT1 STORE COMPANY TO NAME1 STORE ADDRESS1 TO ADR1A STORE ADDRESS2 TO ADR1B STORE CITY + STATE + " " + ZIP TO LAST1 SKIP ENDIF IF .NOT. EOF STORE ATTENTION TO AT2 STORE COMPANY TO NAME2 STORE ADDRESS1 TO ADR2A STORE ADDRESS2 TO ADR2B STORE CITY + STATE + " " + ZIP TO LAST2 SKIP ENDIF DO PRINTLBL SET PRINT ON ? AT1,AT2 ? NAME1,NAME2 ? ADR1A,ADR2A ? ADR1B,ADR2B ? LAST1,LAST2 ? IF EOF STORE F TO GO ENDIF SET PRINT OFF DO PRINTOFF ENDDO SET TALK ON SET CONSOLE ON SET RAW OFF GO TOP RETURN STORE " " TO NAME2 STORE " " TO ADR1A STORE " " TO ADR1B STORE " " TO ADR2A STORE " " TO ADR2B STORE " " TO LAST1 STORE " " TO LAST2 IF .NOT. EOF STORE ATTENTION TO AT1 STORE COMPANY TO NAME1 STORE ADDRESS1 TO ADR1A STORE ADDRESS2 TO ADR1B STORE CITY + STATE + " " + ZIP TO LAST1 SKIP ENDIF IF .NOT. EOF STORE ATTENTION TO AT2 STORE COMPANY TO NAME2 STORE ADDRESS1 TO ADR2A STORE ADDRESS2 TO ADR2B STORE CITY + STATE + " " + ZIP TO LAST2 SKIP ENDIF DO PRINTLBL SET PRINT ON ? AT1,AT2 ? NAME1,NAME2 ? ADR1A,ADR2A ? ADR1B,A* UP2SEL.CMD USE APEXMAIL INDEX MAILZIP STORE " " TO PASS1 STORE " " TO PASS2 STORE " " TO PASS3 STORE " " TO PASS4 STORE " " TO PASS5 STORE " " TO PASS6 STORE " " TO HOLDER STORE 1 TO COUNTER SET FORMAT TO SELECTMN READ SET CONSOLE OFF SET TALK OFF SET RAW ON DO PRINTLBL SET PRINT ON IF PASS1 = " " .AND. PASS2 = " " .AND. PASS3 = " " .AND. PASS4 = " "; .AND. PASS5 = " " .AND. PASS6 = " " SET TALK ON SET CONSOLE ON SET PRINT OFF DO PRINTOFF SET RAW OFF RETURN ENDIF DO WHILE COUNTER < 7 DO CASE CASE COUNTER = 1 STORE PASS1 TO HOLDER CASE COUNTER = 2 STORE PASS2 TO HOLDER CASE COUNTER = 3 STORE PASS3 TO HOLDER CASE COUNTER = 4 STORE PASS4 TO HOLDER CASE COUNTER = 5 STORE PASS5 TO HOLDER CASE COUNTER = 6 STORE PASS6 TO HOLDER ENDCASE IF HOLDER <> " " STORE T TO GO DO WHILE GO STORE " " TO AT1 STORE " " TO AT2 STORE " " TO NAME1 STORE " "  TO NAME2 STORE " " TO ADR1A STORE " " TO ADR1B STORE " " TO ADR2A STORE " " TO ADR2B STORE " " TO LAST1 STORE " " TO LAST2 IF .NOT. EOF DO WHILE GROUP <> HOLDER .AND. .NOT. EOF SKIP ENDDO IF GROUP = HOLDER STORE ATTENTION TO AT1 STORE COMPANY TO NAME1 STORE ADDRESS1 TO ADR1A STORE ADDRESS2 TO ADR1B STORE CITY + STATE + " " + ZIP TO LAST1 ENDIF SKIP ENDIF IF .NOT. EOF DO WHILE GROUP <> HOLDER .AND. .NOT. EOF SKIP ENDDO IF GROUP = HOLDER STORE ATTENTION TO AT2 STORE COMPANY TO NAME2 STORE ADDRESS1 TO ADR2A STORE ADDRESS2 TO ADR2B STORE CITY + STATE + " " + ZIP TO LAST2 ENDIF SKIP ENDIF ? AT1,AT2 ? NAME1,NAME2 ? ADR1A,ADR2A ? ADR1B,ADR2B ? LAST1,LAST2 ? IF EOF STORE F TO GO GOTO TOP ENDIF ENDDO ENDIF STORE COUNTER + 1 TO COUNTER ENDDO DO PRINTOFF SET PRINT OFF SET RAW OFF SET TALK ON SET CONSOLE ON RETURN  " TO ADR2A STORE " " TO ADR2B STORE " " TO LAST1 STORE " " TO LAST2 IF .NOT. EOF DO WHILE GROUP <> HOLDER .AND. .NOT. EOF SKIP ENDDO IF GROUP = HOLDER STORE ATTENTION TO AT1 STORE COMPANY TO NAME1 STORE ADDRESS1 TO ADR1A STORE ADDRESS2 TO ADR1B STORE CITY + STATE + " " + ZIP TO LAST1 ENDIF SKIP ENDIF IF .NOT. EOF DO WHILE GROUP <> HOLDER .AND. .NOT. EOF SKIP ENDDO IF GROUP = HOLDER STORE ATTENTION TO AT2 STORE COMPANY TO NAME2 STORE ADDRESS1 TO ADR2A STORE ADDRESS2 TO ADR2B STORE CITY + STATE + " " + ZIP TO LAST2 ENDIF SKIP ENDIF ? AT1,AT2 ? NAME1,NAME2 ? ADR1A,ADR2A ? ADR1B,ADR2B ? LAST1,LAST2 ? IF EOF STORE F TO GO GOTO TOP ENDIF ENDDO ENDIF STORE COUNTER + 1 TO COUNTER ENDDO DO PRINTOFF SET PRINT OFF SUSE APEXMAIL INDEX MAILZIP SET CONSOLE OFF SET TALK OFF SET RAW ON GO TOP STORE T TO GO DO WHILE GO STORE " " TO AT1 STORE " " TO AT2 STORE " " TO AT3 STORE " " TO NAME1 STORE " " TO NAME2 STORE " " TO NAME3 STORE " " TO ADR1A STORE " " TO ADR1B STORE " " TO ADR2A STORE " " TO ADR2B STORE " " TO ADR3A STORE " " TO ADR3B STORE " " TO LAST1 STORE " " TO LAST2 STORE " " TO LAST3 IF .NOT. EOF STORE ATTENTION TO AT1 STORE COMPANY TO NAME1 STORE ADDRESS1 TO ADR1A STORE ADDRESS2 TO ADR1B STORE CITY + STATE + " " + ZIP TO LAST1 SKIP ENDIF IF .NOT. EOF STORE ATTENTION TO AT2 STORE COMPANY TO NAME2 STORE ADDRESS1 TO ADR2A STORE ADDRESS2 TO ADR2B STORE CITY + STATE + " " + ZIP TO LAST2 SKIP ENDIF IF .NOT. EOF STORE ATTENTION TO AT3 STORE COMPANY TO NAME3 STORE ADDRESS1 TO ADR3A STORE ADDRESS2 TO ADR3B STORE CITY + STATE + " " + ZIP TO LAST3 SKIP ENDIF DO PRINTLBL SET PRINT ON ? AT1,AT2,AT3 ? NAME1,NAME2,NAME3 ? ADR1A,ADR2A,ADR3A ? ADR1B,ADR2B,ADR3B ? LAST1,LAST2,LAST3 ? IF EOF STORE F TO GO ENDIF SET PRINT OFF DO PRINTOFF ENDDO SET TALK ON SET CONSOLE ON SET RAW OFF GO TOP RETURN  " TO ADR3A STORE " " TO ADR3B STORE " " TO LAST1 STORE " " TO LAST2 STORE " " TO LAST3 IF .NOT. EOF STORE ATTENTION TO AT1 STORE COMPANY TO NAME1 STORE ADDRESS1 TO ADR1A STORE ADDRESS2 TO ADR1B STORE CITY + STATE + " " + ZIP TO LAST1 SKIP* UP3SEL.CMD USE APEXMAIL INDEX MAILZIP STORE " " TO PASS1 STORE " " TO PASS2 STORE " " TO PASS3 STORE " " TO PASS4 STORE " " TO PASS5 STORE " " TO PASS6 STORE " " TO HOLDER STORE 1 TO COUNTER SET FORMAT TO SELECTMN READ SET CONSOLE OFF SET TALK OFF SET RAW ON DO PRINTLBL SET PRINT ON IF PASS1 = " " .AND. PASS2 = " " .AND. PASS3 = " " .AND. PASS4 = " "; .AND. PASS5 = " " .AND. PASS6 = " " SET TALK ON SET CONSOLE ON DO PRINTOFF SET PRINT OFF SET RAW OFF RETURN ENDIF DO WHILE COUNTER < 7 DO CASE CASE COUNTER = 1 STORE PASS1 TO HOLDER CASE COUNTER = 2 STORE PASS2 TO HOLDER CASE COUNTER = 3 STORE PASS3 TO HOLDER CASE COUNTER = 4 STORE PASS4 TO HOLDER CASE COUNTER = 5 STORE PASS5 TO HOLDER CASE COUNTER = 6 STORE PASS6 TO HOLDER ENDCASE IF HOLDER <> " " STORE T TO GO DO WHILE GO STORE " " TO AT1 STORE " " TO AT2 STORE " " TO AT3 STORE " " TO  NAME1 STORE " " TO NAME2 STORE " " TO NAME3 STORE " " TO ADR1A STORE " " TO ADR1B STORE " " TO ADR2A STORE " " TO ADR2B STORE " " TO ADR3A STORE " " TO ADR3B STORE " " TO LAST1 STORE " " TO LAST2 STORE " " TO LAST3 IF .NOT. EOF DO WHILE GROUP <> HOLDER .AND. .NOT. EOF SKIP ENDDO IF GROUP = HOLDER STORE ATTENTION TO AT1 STORE COMPANY TO NAME1 STORE ADDRESS1 TO ADR1A STORE ADDRESS2 TO ADR1B STORE CITY + STATE + " " + ZIP TO LAST1 ENDIF SKIP ENDIF IF .NOT. EOF DO WHILE GROUP <> HOLDER .AND. .NOT. EOF SKIP ENDDO IF GROUP = HOLDER STORE ATTENTION TO AT2 STORE COMPANY TO NAME2 STORE ADDRESS1 TO ADR2A STORE ADDRESS2 TO ADR2B STORE CITY + STATE + " " + ZIP TO LAST2 ENDIF SKIP ENDIF IF .NOT. EOF DO WHILE GROUP <> HOLDER .AND. .NOT. EOF SKIP ENDDO IF GROUP = HOLDER STORE ATTENTION TO AT3 STORE COMPANY TO NAME3 STORE ADDRESS1 TO ADR3A STORE ADDRESS2 TO ADR3B STORE CITY + STATE + " " + ZIP TO LAST3 ENDIF SKIP ENDIF ? AT1,AT2,AT3 ? NAME1,NAME2,NAME3 ? ADR1A,ADR2A,ADR3A ? ADR1B,ADR2B,ADR3B ? LAST1,LAST2,LAST3 ? IF EOF STORE F TO GO GOTO TOP ENDIF ENDDO ENDIF STORE COUNTER + 1 TO COUNTER ENDDO SET PRINT OFF DO PRINTOFF SET RAW OFF SET TALK ON SET CONSOLE ON RETURN  GROUP = HOLDER STORE ATTENTION TO AT1 STORE COMPANY TO NAME1 STORE ADDRESS1 TO ADR1A STORE ADDRESS2 TO ADR1B STORE CITY + STATE + " " + ZIP TO LAST1 ENDIF SKIP ENDIF IF .NOT. EOF DO WHILE GROUP <> HOLDER .AND. .NOT. EOF SKIP ENDDO IF GROUP = HOLDER STORE ATTENTION TO AT2 STORE COMPANY TO NAME2 STORE ADDRESS1 TO ADR2A STORE ADDRESS2 TO ADR2B STORE* UPDATE.CMD ERASE RELEASE ALL STORE " " TO ANSWER DO WHILE T SET FORMAT TO UPDATEMN READ DO CASE CASE ANSWER = "1" ERASE USE APEXMAIL INDEX MAILCOMP,MAILZIP APPEND ERASE CASE ANSWER = "2" DO SEARCH IF * RECALL ELSE DELETE ENDIF CASE ANSWER = "3" DO SEARCH IF # = 0 RETURN ENDIF ERASE EDIT # ERASE CASE ANSWER = "4" ERASE ? ? ? ? "WARNING! WARNING! WARNING!" ? ? ? "If you continue with this command, all files" ? "marked for deletion will be PERMANENTLY erased." ? ? "Type 'yes' to continue, anything else to abort." ? ACCEPT TO PERMS IF !(PERMS) = "YES" USE APEXMAIL INDEX MAILCOMP,MAILZIP PACK ENDIF ERASE CASE ANSWER = "5" RETURN ENDCASE STORE " " TO ANSWER STORE " " TO PERMS ENDDO ALPH FRM/APEXMAILDBF 01CARDS CMD 23DUMP FRM4HELLO CMD5LABELMENFMT 67LABELS CMD8DSCREEN CMD9:;<=>?@ABCDEFGH * UPDATEMN.FMT @ 1, 0 SAY "+=================================================" @ 1,50 SAY "=+" @ 2, 0 SAY "| APEX TOOLWORKS- General Mailing List Manager." @ 2,51 SAY "|" @ 3, 0 SAY "+=================================================" @ 3,50 SAY "=+" @ 4, 0 SAY "|" @ 4,51 SAY "|" @ 5, 0 SAY "| Select from the following list by number-" @ 5,51 SAY "|" @ 6, 0 SAY "|" @ 6,51 SAY "|" @ 7, 0 SAY "|" @ 7,51 SAY "|" @ 8, 0 SAY "| 1) Add new records." @ 8,51 SAY "|" @ 9, 0 SAY "|" @ 9,51 SAY "|" @ 10, 0 SAY "| 2) Mark or unmark a record for deletion." @ 10,51 SAY "|" @ 11, 0 SAY "|" @ 11,51 SAY "|" @ 12, 0 SAY "| 3) Edit a record." @ 12,51 SAY "|" @ 13, 0 SAY "|" @ 13,51 SAY "|" @ 14, 0 SAY "| 4) Purge the file of records marked for" @ 14,51 SAY "|" @ 15, 0 SAY "| deletion. WARNING!!! PERMANENT !!" @ 15,51 SAY "|" @ 16, 0 SAY "|" @ 16,51 SAY "|" @ 17, 0 SAY "| 5) Return to the main menu." @ 17,51 SAY "|" @ 18, 0 SAY "|" @ 18,51 SAY "|" @ 19, 0 SAY "|" @ 19,51 SAY "|" @ 20, 0 SAY "| What is your selection?" @ 20,26 GET answer @ 20,51 SAY "|" @ 21, 0 SAY "|" @ 21,51 SAY "|" @ 22, 0 SAY "+-------------------------------------------------" @ 22,50 SAY "-+"SAY "=+" @ 4, 0 SAY "|" @ 4,51 SAY "|" @ 5, 0 SAY "| Select from the following list by number-" @ 5,51 SAY "|" @ 6, 0 SAY "|" @ 6,51 SAY "|" @ 7, 0 SAY "|" @ 7,51 SAY "|" @ 8, 0 SAY "| 1) Add new records." @ 8,51 SAY "|" @ 9, 0 SAY "|" @ 9,51 SAY "|" @ 10, 0 SAY "| 2) Mark or unmark a record for deletion." @ 10,51 SAY "|" @ 11, 0 SAY "|" @ 11,51 SAY "|" @ 12, 0 SAY "| 3) Edit a record." @ 12,51 SAY "|" @ 13, 0 SAY "|" @ 13,51 SAY "|" @ 14, 0 SAY "| 4) Purge the file of records marked for" @ 14,51 SAY "|" @ 15, 0 SAY "| deletion. WARNING!!! PERMANENT !!" @ 15,51 SAY "|" @ 16, 0 SAY "|" @ 16,51 SAY "|" @ 17, 0 SAY "| 5) Return to the main menu." @ 17,51 SAY "|" @ 18, 0 SAY "|" @ 18,51 SAY "|" @ COMPNAME dADDR1 $dADDR2 FdATTN hdCTdSTdZP dGRPd " " " "     WELDON TOOL COMPANY 3000 WOODHILL ROAD CLEVELAND OH44104 CHUCK TILDEN A STARRETT INDUSTRIAL SUPPLY CO. SUITE 234 1200 EAST HAVERHILL ROAD PONTIAC MI48057 T. CARGILL C NIKON VISIONS, NIKON INC. INSTRUMENTATION DIVISION 623 STEWART AVENUE GARDEN CITY NY11530 M. SHULTZEN A HARDINGE BROTL=50,W=132 Y APEX TOOLWORKS INC. Y N 32,COMPANY COMPANY NAME;-------------------- 32,ADDRESS1 ADDRESS LINE 1;------------------ 32,ADDRESS2 ADDRESS LINE 2;------------------ 18,CITY CITY;-------------- 2,STATE ST 10,ZIP ZIP 32,ATTENTION ATTENTION / TO;------------------ 4,GROUP GRP  ROCKFORD IL61103 C DI-ACRO / HOUDAILLE LAKE CITYUP1LBL CMDUP1SEL CMD UP2LBL CMD !UP2SEL CMD"#$UP3LBL CMD %&UP3SEL CMD'()UPDATE CMD*UPDATEMNFMT +,ADD MEM-./ALPH $$$CARDS CMD 23DUMP FRM4HELLO CMD5LABELMENFMT 67LABELS CMD8DSCREEN CMD9:;<=>?@ABCDEFGHCOMPANYC lADDRESS1C lADDRESS2C mCITYC1mSTATECCmZIPC EmATTENTIONC OmGROUPCom ANILAM ELECTRONICS CORPORATION 5625 NORTH WEST 79TH AVENUE MIAMI FL33166 HUAN HUNG LOW B WALTER 1003 LENDALL LANE POST OFFICE BOX 5427 FREDERICKSBURG VA22403 C. HILLER C WASINO CORPORATION USA 400 OSER AVENUE HAUPPAUGE NY11788 C WESTINGHOUSE  ELECTRIC CORP. INDUSTRY AUTOMATION DIVISION 2040 ARDMORE BOULEVARD PITTSBURGH PA15221 D. GRISWOLD A WESTINGHOUSE ELECTRIC- UNIMATION400 HIGH TOWER BUILDING 400 MEDIA DRIVE PITTSBURGH PA15205 N. SHAGE A WHITE CONSOLIDATED INDUSTRIES MACHINE TOOL GROUP 286 CANFIELD AVENUE BRIDGEPORT CT06609 B WASINO CORPORATION USA 400 ANILAM ELECTRONICS CORPORATION 5625 NORTH WEST 79TH AVENUE MIAMI FL33166 HUAN HUNG LOW B WALTER 1003 LENDALL LANE POST OFFICE BOX 5427 FREDERICKSBURG VA22403 C. HILLER C WASINO CORPORATION USA 400 OSER AVENUE HAUPPAUGE NY11788 C WESTINGHOUSE ERASE USE APEXMAIL INDEX MAILZIP STORE " " TO LINE1 STORE " " TO LINE2 STORE " " TO LINE3 STORE " " TO LINE4 STORE " " TO LINE5 STORE " " TO LINE6 STORE " " TO LINE7 STORE " " TO LINE8 STORE " " TO LINE9 STORE " " TO LINE10 STORE " " TO LINE11 STORE " " TO LINE12 STORE " " TO LINE13 STORE " " TO LINE14 SET FORMAT TO POSTCARD READ GO TOP SET TALK OFF SET RAW ON SET CONSOLE OFF SET PRINT ON DO WHILE .NOT. EOF ? ? ? ? ? LINE1 ? LINE2 ? LINE3 ? LINE4 ? LINE5 ? LINE6 ? LINE7 ? LINE8 , " " , ATTENTION ? LINE9 , " " , COMPANY ? LINE10 , " " , ADDRESS1 ? LINE11 , " " , ADDRESS2 ? LINE12 , " " , TRIM(CITY) + ", " + STATE + " " + ZIP ? LINE13 ? LINE14 ? ? SKIP ENDDO SET RAW OFF SET PRINT OFF SET CONSOLE ON SET TALK ON USE APEXMAIL INDEX MAILCOMP RETURN  " TO LINE6 STORE " " TO LINE7 STORE " " TO LINE8 STORE " " TO LINE9 STORE " " TO LINE10 STORE " " TO LINE11 STORE " " TO LINE12 STORE " " TO LINE13 STORE " " TO LINE14 SET FORMAT TO POSTCARD READ GO TOP SET TALK OFF SET RAW ON SET CONSOLE OFF SET PRINT ON DO WHILE .NOT. EOF ? ? ? ? ? LINE1 ? LINE2 ? LINE3 ? LINE4 ? LINE5 ? LINE6 ? LINE7 ? LINE8 , " " , ATTENTION ? LINE9 , " " , COML=60 N Y N 36,COMPANY ------ COMPANY NAME ------------ 36,ADDRESS1 ------- ADDRESS LINE 1 --------- 38,ADDRESS2 ------- ADDRESS LINE 2 --------- 20,CITY ----- CITY ------ 6,STATE STATE 10,ZIP -- ZIP -- 38,ATTENTION ------- ATTENTION / TO: ---------- 8,GROUP GROUP 5205 N. SHAGE A NATIONAL MACHINERY COMPANY BUILDING AD-133 1231 INDUSTRIAL BOUP1LBL CMDUP1SEL CMD UP2LBL CMD !UP2SEL CMD"#$UP3LBL CMD %&UP3SEL CMD'()UPDATE CMD*UPDATEMNFMT +,ADD MEM-./ALPH FRM0APEXMAILDBF 12CARDS CMD 34DUMP $$$LABELMENFMT 67LABELS CMD8DSCREEN CMD9:;<=>?@ABCDEFGH* hello.cmd SET INTENSITY OFF SET TALK OFF ERASE SET DEFAULT TO B: USE APEXMAIL INDEX MAILCOMP,MAILZIP DO PRELUDE IF .NOT. FILE ( "ADD.MEM" ) DO MAKEMEM ENDIF ERASE STORE " " TO ANSWER DO WHILE T SET FORMAT TO MAINMENU READ DO CASE CASE ANSWER = "1" DO UPDATE CASE ANSWER = "2" DO MAILREP CASE ANSWER = "3" DO LABELS CASE ANSWER = "4" DO CARDS CASE ANSWER = "5" ERASE CANCEL CASE ANSWER = "6" SET CONSOLE OFF QUIT ENDCASE STORE " " TO ANSWER ENDDO UP1LBL CMDUP1SEL CMD UP2LBL CMD !UP2SEL CMD"#$UP3LBL CMD %&UP3SEL CMD'()UPDATE CMD*UPDATEMNFMT +,ADD MEM-./ALPH FRM0APEXMAILDBF 12CARDS CMD 34DUMP FRM5HELLO $$$LABELS CMD8DSCREEN CMD9:;<=>?@ABCDEFGH * LABELMEN.FMT @ 1, 0 SAY "+-------------------------------------------------" @ 1,50 SAY "-+" @ 2, 0 SAY "| APEX TOOLWORKS- General Mailing List Manager." @ 2,51 SAY "|" @ 3, 0 SAY "+-------------------------------------------------" @ 3,50 SAY "-+" @ 4, 0 SAY "|" @ 4,51 SAY "|" @ 5, 0 SAY "| Select a print option by number-" @ 5,51 SAY "|" @ 6, 0 SAY "|" @ 6,51 SAY "|" @ 7, 0 SAY "| 1) 1 across labels, all companies." @ 7,51 SAY "|" @ 8, 0 SAY "|" @ 8,51 SAY "|" @ 9, 0 SAY "| 2) 2 across labels, all companies." @ 9,51 SAY "|" @ 10, 0 SAY "|" @ 10,51 SAY "|" @ 11, 0 SAY "| 3) 3 across labels, all companies." @ 11,51 SAY "|" @ 12, 0 SAY "|" @ 12,51 SAY "|" @ 13, 0 SAY "| 4) 1 across labels, select groups." @ 13,51 SAY "|" @ 14, 0 SAY "|" @ 14,51 SAY "|" @ 15, 0 SAY "| 5) 2 across labels, select groups." @ 15,51 SAY "|" @ 16, 0 SAY "|" @ 16,51 SAY "|" @ 17, 0 SAY "| 6) 3 across labels, select groups." @ 17,51 SAY "|" @ 18, 0 SAY "|" @ 18,51 SAY "|" @ 19, 0 SAY "| 7) RETURN to the main menu." @ 19,51 SAY "|" @ 20, 0 SAY "|" @ 20,51 SAY "|" @ 21, 0 SAY "| What is your choice?" @ 21,24 GET answer @ 21,51 SAY "|" @ 22, 0 SAY "+-------------------------------------------------" @ 6,51 SAY "|" @ 7, 0 SAY "| 1) 1 across labels, all companies." @ 7,51 SAY "|" @ 8, 0 SAY "|" @ 8,51 SAY "|" @ 9, 0 SAY "| 2) 2 across labels, all companies." @ 9,51 SAY "|" @ 10, 0 SAY "|" @ 10,51 SAY "|" @ 11, 0 SAY "| 3) 3 across labels, all companies." @ 11,51 SAY "|" @ 12, 0 SAY "|" @ 12,51 SAY "|" @ 13, 0 SAY "| 4) 1 across labels, select groups." @ 13,51 SAY "|" @ 14, 0 SAY "|" @ 14,51 SAY "|" @ 15, 0 SAY "| 5) 2 across labels, select groups." @ 15,51 SAY "|" @ 16, 0 SAY "|" @ 16,51 SAY "|" @ 17, 0 SAY "| 6) 3 across labels, select groups* labels.cmd ERASE STORE " " TO ANSWER DO WHILE T SET FORMAT TO LABELMEN.FMT READ DO CASE CASE ANSWER = "1" DO UP1LBL CASE ANSWER = "2" DO UP2LBL CASE ANSWER = "3" DO UP3LBL CASE ANSWER = "4" DO UP1SEL CASE ANSWER = "5" DO UP2SEL CASE ANSWER = "6" DO UP3SEL CASE ANSWER = "7" RETURN ENDCASE STORE " " TO ANSWER ENDDO PRINTREPCMDREP FMT SEARCH CMDSELECTMNFMT UP1LBL CMDUP1SEL CMD UP2LBL CMD !UP2SEL CMD"#$UP3LBL CMD %&UP3SEL CMD'()UPDATE CMD*UPDATEMNFMT +,ADD MEM-./ALPH FRM0APEXMAILDBF 12CARDS CMD 34DUMP FRM5HELLO CMD6LABELMENFMT 78LABELS $$$*********************************************************************** * Program Name.........: dSCREEN.CMD/PRG * Purpose..............: DATA ENTRY SCREEN CODE GENERATOR FOR dBASE II * Author...............: MARK C. SCARAMELLA * * ==================================================================== * * Copyright Notice.....: Copyright (C) 1984, Mark C. Scaramella * All rights reserved * Released to the Public Domain * Not for resale without the explicit permission * of the author. Modifications for personal * use are authorized and encouraged. * Please notify author of any improvements or * fixes implemented or requested at: * * Mark C. Scaramella * c/o ESD Corporation * 600 Meridian Ave. * San Jose, CA 95126 * *  Telephone calls cannot be responded to, * Letters only please. * * If you like dSCREEN and find it helpful and * you would like to contribute to its "growth and * development", please send a donation of $20.00 * (or more) to the above address. * * ======================================================================= * * Date................: 1/27/85 * Version.............: 1.3 with high/low exclusion * Date Fields,Req'd Fields,Calc Fields,Heading * Date Reversal/Compression,Index Files,NOUP * dBASE II Version....: 2.4 and up. Should work with 2.3b, but not * thoroughly tested under 2.3b (must remove NOUP * command, SET DELETED ON command, must remark out/ * remove CASE statements which test for files. or * re-write them as IF statements which seem to work.) * Updates under consideration: * - Automatic Table lookup * - Automatic Field/File Name validity checking * in output command file. * - Logical Field Support * Comment/Notes.......: - Picture Clause and numeric fields don't * work with underlines * - Logical Field Types are not supported * (Logical Fields will be flagged.) * - Field Sequence defaults to record number * - No checking for file existence except at * start up. This allows for automatic write- * over of command files during generation. * - Generator gets confused by 10 character * field names becuase of "M" added for memory * variables. Avoid 10 character field names *  or... modify the command file output. ************************************************************************ set talk off erase ? ? ? ? ' - - d S C R E E N - -' ? ? ' AN AUTOMATIC COMMAND FILE GENERATOR FOR dBASE II DATA ENTRY' ? ? ' by Mark Scaramella' ? ? ' Version 1.3 01/27/85' ? ? ? if .not. file('XSCREEN.dbf') ? CHR(7)+'Sorry, XSCREEN.DBF must be on the default disk for this program to run.' ? 'See program documentation/comments for details.' ? 'Re-start when XSCREEN.DBF is set up.' cancel endif ? '(P)revious or (N)ew Screen Data Base Definition File ? ' wait to ans if !(ans)='N' * STEP ONE: MAKE A DATABASE FILE FROM THE STRUCTURE OF THE SOURCE * FILE USING THE PREVIOUSLY DEFINED FILE: XSCREEN.DBF WITH THE * FOLLOWING CHARACTERISTICS: * *STRUCTURE FOR FILE: D:XSCREEN .DBF *NUMBER OF RECORDS: 00000 *DATE OF LAST UPDATE: 01/27/85 *PRIMARY USE DATABASE *FLD NAME TYPE WIDTH DEC *001 FIELD:NAME C 010 *002 ALIAS C 030 *003 FIELD:TYPE C 002 *004 FIELD:LEN N 003 *005 FIELD:DEC N 003 *006 SEQUENCE N 002 *007 ROW N 002 *008 ACOL N 003 *009 FCOL N 003 *010 CARRY C 002 *011 DEFAULT C 050 *012 PICTURE C 050 *013 REQD C 002 *014 FILL C 002 *015 HIGH C 010 *016 LOW C 010 *017 FORMULA C 050 *018 INDEX C 002 *019 USED C 002 *** TOTAL ** 00239 ACCEPT "Enter database source file name " to dbfile stor !(trim(dbfile)) to dbfile DO CASE CASE DBFILE = " " cancel CASE .NOT. FILE("&DBFILE") ? CHR(7)+"FILE DOES NOT EXIST (on this drive)" ? "Please re-start." cancel ENDCASE use &dbfile copy stru exte to stemp use xscreen if "."$dbfile stor !($(dbfile,1,@(".",dbfile))+"dbs") TO dbscreen else stor !(dbfile+".dbs") TO dbscreen ENDIF acce 'Enter screen database file name to be created (Default: &dbscreen) ' to dbscrn if dbscrn#" " stor dbscrn to dbscreen endif copy stru to &dbscreen use &dbscreen appe from stemp repl all sequence with # dele file stemp ? ? '&dbscreen file created. You may now edit &dbscreen (which is' ? 'in use now) with your screen characteristics. Re-start this' ? 'Program after editing. Use &dbscreen as the "(P)revious" file' ? 'when prompted.' cancel else IF FILE("dscreen.cmd") STOR "CMD" TO mtyp ELSE STOR "PRG" TO mtyp ENDIF * STEP TWO: * SCREEN DATABASE FILE ALREADY EXISTS AND EDITED, READY FOR PROCESSING ? 'Screen database file with your screen characteristics (Default type .DBS) ' ACCE TO scrfile IF .NOT."."$scrfile STOR scrfile+".DBS" TO scrfile ENDIF DO CASE CASE SCRFILE = " " cancel CASE .NOT. FILE("&SCRFILE") ? CHR(7)+"FILE DOES NOT EXIST (on this drive)" ? "Please re-start." cancel ENDCASE use &scrfile endif go bott stor $(str(0,81),1,80) to mbl if #<20 ACCE 'Enter Screen Heading ' to mshead stor $(mbl,1,(80-len(trim(mshead)))/2)+mshead to mshead else stor 'X' to mshead endif if #>22 ? ? '*** More than 22 fields in screen database, some command file' ? 'modification will be required after it is generated.' ? endif * SEE IF USER HAS OVERRIDDEN @SAY/@GET POSITIONS IN THE SCREEN DATABASE ? ? 'Command file only?' ? ? '(Say yes at this point if you have entered new row' ? 'and column positions into the screen database file)' ? wait to mcmdans if !(mcmdans)="N" repl all acol with 1 * DETERMINE WIDEST FIELD ALIAS NAME INDE ON 100-LEN(TRIM(ALIAS)) TO ALEN GO TOP * IGNORE UNUSED FIELDS DO WHILE !(USED)='N' SKIP ENDDO STOR LEN(TRIM(ALIAS)) TO AMAXLEN STOR 77-AMAXLEN TO FMAXLEN set inde to DELE FILE ALEN.NDX repl all used with 'N' for formula#' ' INDE ON SEQUENCE TO SEQ GO TOP STOR 1 TO MCOL if mshead='X' stor 1 to mrow else stor 3 to mrow endif * FIRST LOOP CALCULATES ROW/COL POSITIONS AND CHECKS FOR DATE FIELDS DO WHILE .NOT. EOF IF !(USED)='N' SKIP LOOP ENDIF IF 'DATE'$!(FIELD:NAME).OR.'DATE'$!(ALIAS) repl field:type with 'D' REPL PICTURE WITH '99/99/99' ENDIF STOR LEN(TRIM(ALIAS))+FIELD:LEN TO TLEN REPL ROW WITH MROW,ACOL WITH MCOL REPL FCOL WITH AMAXLEN+1 STOR MROW+1 TO MROW SKIP ENDDO ? ? 'Field characteristics generation complete.' ? ? 'Do you want to continue with command file generation?' ? ? '(Stopping now and restarting later will allow manual editing' ? 'of alias and field screen characteristics before re-starting.)' ? wait to ans if !(ans)='N' cancel endif endif * NOW GENERATE THE COMMAND FILE * DETERMINE THE WIDEST FIELD ALIAS NAME INDE ON 100-LEN(TRIM(ALIAS)) TO ALEN GO TOP DO WHILE !(USED)='N' SKIP ENDDO STOR LEN(TRIM(ALIAS)) TO AMAXLEN STOR 77-AMAXLEN TO FMAXLEN set inde to DELE FILE ALEN.NDX INDE ON SEQUENCE TO SEQ GO TOP ACCE 'Name of command file to be generated ' to cmdfile ? acce 'Name of database file to be used ' TO mdbf ? 'Name index file(s) to be used (separated by commas) if applicable' acce TO mndx ? ? 'Fill field entry area with (B)lanks or (U)nderlines ? ' wait to ans IF .NOT."."$cmdfile STOR CMDFILE+'.'+MTYP TO CMDFILE ENDIF set alte to &cmdfile set alte on Stor '...................................................' to mdots go top * GENERATE DRAFT PROGRAM DOCUMENTATION ? '***********************************************************************' ? '* Program Name.....: '+cmdfile ? '* Purpose..........: Data Entry For '+MDBF IF mndx#" " ?? 'Index &mndx' ENDIF ? '* Author...........: Your Name' ? '* Copyright Notice.: Copyright (C) 1985, Your Name, All rights reserved' ? '* Date.............: '+date() ? '* dBASE II version.: 2.4x' ? '* CMD file version : 1.0' ? '* Memory Variables.: "M"+Field names + control variables +...?' ? '* Comments/Notes...:  ' ? '* : ' ? '***********************************************************************' * SET "SETS" TO YOUR OWN TASTE ? '* ---- ENVIRONMENT SECTION:' ? ? '* Reset dBASE II with no active data bases and no memory variables' ? 'CLEAR' ? 'SET STEP OFF ".......... Obviously."' ? 'SET PRINT OFF "......... Obviously."' ? 'SET ECHO OFF ".......... Obviously (unless you want to see commands)"' ? 'SET TALK OFF ".......... Obviously (unless you want to see calculations)"' ? 'SET ALTERNATE OFF "..... Obviously."' ? 'SET ALTERNATE TO' ? 'SET BELL OFF ".......... Obviously. The Bell implementation is useless"' ? 'SET CARRY OFF "......... This seems like a good default state"' ? 'SET COLON ON ".......... Important. Not every screen has intensity"' ? 'SET CONFIRM OFF "....... Optional. You may want to default to ON."' ? 'SET CONSOLE ON "........ Obviously."' ? 'SET DEBUG OFF "......... Obviously."' ? 'SET DELETED ON "........ Optional. ON prevents DELETEd records from being"' ? '* included in a command with a scope (v. 2.4 only)' ? 'SET EJECT OFF "......... This eliminates Ejects before printout and"' ? '* requires an EJECT at the completion of a printout' ? 'SET ESCAPE OFF "........ Optional. You may want to run with ESCAPE ON"' ? 'SET EXACT OFF "......... Optional (though usual default is OFF)"' ? 'SET FORMAT TO SCREEN ".. Obviously."' ? 'SET INTENSITY OFF "..... Different screens have different ways of"' ? '* presenting intensity. It is good to start with' ? '* it off and control it.' ? 'SET LINKAGE OFF "....... Obviously."' ? 'SET RAW ON "............ Optional (though this is a good default position"' ? '* to prevent problems with semi-colons)' ? 'SET SCREEN ON "......... Obviously."' ? 'ERASE "................. Clear the screen"' ? ? '* Put 79 blanks in a global memory variable' ? 'STORE $(STR(0,80),1,79) TO gmbl' ? ? 'USE &mdbf' IF !(ANS)='U' ? 'STOR "_____________________________________________________________" TO MBL80' ELSE ? '* ---- MEMORY VARIABLE INITIALIZATION:' ? ? 'STOR $(STR(0,81),1,80) TO MBL80' ENDIF DO WHILE .NOT. EOF if !(FIELD:TYPE)='L' ? '*** Logical Field types not yet supported, CMD/PRG file editing required' ? '*** Logical Field Name: '+Field:name REPL USED WITH 'N' endif IF !(USED)='N' SKIP LOOP ENDIF * SET UP DEFAULTS AND INITIALIZE VARIABLES DO CASE CASE FIELD:TYPE='C' * TRUNCATE VERY LONG FIELDS, TOO HARD TO HANDLE IN THIS SYSTEM * IF LONG FIELDS ARE REQUIRED, USE EDITOR ON COMMAND FILE AFTER * SUCCESSFUL CREATION/TEST. IF FIELD:LEN>FMAXLEN IF DEFAULT=' ' ? '*** LONG FIELD NAME, SUBSTRING USED TO FIT' ? 'STOR $(MBL80,1,'+STR(FMAXLEN,3)+') TO M'+TRIM(field:name) ELSE ? '*** LONG FIELD NAME, SUBSTRING USED TO FIT' ? 'STOR $("'+TRIM(DEFAULT)+'"+MBL80,1,'+STR(FMAXLEN,3)+') TO M'+TRIM(field:name) ENDIF ELSE IF DEFAULT=' ' ? 'STOR $(MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(field:name) ELSE ? 'STOR $("'+TRIM(DEFAULT)+'"+MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(field:name) ENDIF ENDIF CASE FIELD:TYPE='N' IF VAL(DEFAULT)=0 ? 'STOR 0 TO M'+TRIM(field:name) ELSE ? 'STOR '+trim(DEFAULT)+' TO M'+TRIM(field:name) ENDIF CASE FIELD:TYPE='D' IF DEFAULT=' ' ? 'STOR $(MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(field:name) ELSE ? 'STOR $("'+TRIM(DEFAULT)+'"+MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(field:name) ENDIF ENDCASE SKIP ENDDO GO TOP ? '* ----- SCREEN FORMAT INITIALIZATION:' ? ? 'ERASE' * GENERATE @SAYS ONE TIME BEFORE STARTING GET LOOP ? 'SET INTE ON' DO WHILE .NOT. EOF IF !(USED)='N' SKIP LOOP ENDIF IF FCOL<=31 ? '@ '+STR(ROW,2)+', '+STR(ACOL,2)+' SAY "'+$(TRIM(ALIAS)+MDOTS,1,FCOL)+':"' ELSE ? '@ '+STR(ROW,2)+', '+STR(ACOL,2)+' SAY "'+$(TRIM(ALIAS)+MDOTS,1,LEN(TRIM(ALIAS))+2)+':"' ENDIF SKIP ENDDO * GENERATE LOOP START-UP STATEMENTS ? 'SET INTE OFF' ? ? 'GO BOTT' ? 'STOR #+1 TO MRECNO' IF mndx#" " ? 'SET INDEX TO &mndx' ENDIF ? 'STOR " " TO MOK' ? 'DO WHILE T' ? ' @ 23,68 SAY "REC NO:"+STR(MRECNO,4)' if mshead#'X' ? '@ 1,1 say "&mshead"' ? '@ 2,1 say "==============================================================================="' ? '@ 22,1 say "==============================================================================="' endif * GENERATE @GETS/PICTURES ? '* ----- DATA INPUT SECTION:' ? GO TOP ? 'SET INTE ON' DO WHILE .NOT. EOF IF !(USED)='N' SKIP LOOP ENDIF IF PICTURE=' ' ? ' @ '+STR(ROW,2)+', '+STR(FCOL+2,2)+' GET M'+TRIM(field:name) ELSE ? ' @ '+STR(ROW,2)+', '+STR(FCOL+2,2)+' GET M'+TRIM(field:name)+' PICT '+'"'+!(TRIM(PICTURE))+'"' ENDIF SKIP ENDDO * GENERATE READ AND END LOGIC GO TOP ? ' READ NOUP' ? 'SET INTE OFF' ? ' @ 23,0 SAY $(STR(0,80),1,79)' * GENERATE REQUIRED FIELD LOGIC ? '* ----- DATA VALIDATION SECTION:' ? GO TOP IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF M'+TRIM(field:name)+' # " "' ELSE ? ' IF M'+TRIM(field:name)+'>0' ENDIF DO WHILE .NOT. EOF IF !(REQD)='Y' IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF M'+TRIM(FIELD:NAME)+' = " "' ELSE ? ' IF M'+TRIM(FIELD:NAME)+' = 0' ENDIF ? ' @ 23,10 SAY CHR(7)' ? ' @ 23,10 SAY "'+TRIM(ALIAS)+' IS A REQUIRED ENTRY, PLEASE RE-ENTER"' ? ' CLEAR GETS' ? ' LOOP' ? ' ENDIF' ENDIF IF !(FILL)='Y' IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF " "$M'+TRIM(FIELD:NAME) ? ' @ 23,10 SAY CHR(7)' ? ' @ 23,10 SAY "'+TRIM(ALIAS)+' MUST BE COMPLETELY FILLED, PLEASE RE-ENTER"' ? ' CLEAR GETS' ? ' LOOP' ? ' ENDIF' ENDIF ENDIF SKIP ENDDO * GENERATE HIGH AND LOW LIMIT LOGIC GO TOP DO WHILE .NOT. EOF IF HIGH=' '.AND.LOW=' ' SKIP LOOP ENDIF IF HIGH=' '.AND.LOW#' ' IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF M'+TRIM(FIELD:NAME)+' < "'+TRIM(LOW)+'"' ELSE ? ' IF M'+TRIM(FIELD:NAME)+' < '+TRIM(LOW) ENDIF ? ' @ 23,10 SAY CHR(7)' ? ' @ 23,10 SAY "'+TRIM(ALIAS)+' CANNOT BE BELOW '+TRIM(LOW)+', PLEASE RE-ENTER"' ? ' CLEAR GETS' ? ' LOOP' ? ' ENDIF' ELSE IF HIGH#' '.AND.LOW=' ' IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF M'+TRIM(FIELD:NAME)+' > "'+TRIM(HIGH)+'"' ELSE ? ' IF M'+TRIM(FIELD:NAME)+' > '+TRIM(HIGH) ENDIF ? ' @ 23,10 SAY CHR(7)' ? ' @ 23,10 SAY "'+TRIM(ALIAS)+' CANNOT BE ABOVE '+TRIM(HIGH)+', PLEASE RE-ENTER"' ? ' CLEAR GETS' ? ' LOOP' ? ' ENDIF' ELSE IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF M'+TRIM(FIELD:NAME)+' < "'+TRIM(LOW)+'"' ELSE ? ' IF M'+TRIM(FIELD:NAME)+' < '+TRIM(LOW) ENDIF ? ' @ 23,10 SAY CHR(7)' ? ' @ 23,10 SAY "'+TRIM(ALIAS)+' CANNOT BE BELOW '+TRIM(LOW)+', PLEASE RE-ENTER"' ? ' CLEAR GETS' ? ' LOOP' ? ' ENDIF' IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF M'+TRIM(FIELD:NAME)+' > "'+TRIM(HIGH)+'"' ELSE ? ' IF M'+TRIM(FIELD:NAME)+' > '+TRIM(HIGH) ENDIF ? ' @ 23,10 SAY "'+TRIM(ALIAS)+' CANNOT BE ABOVE '+TRIM(HIGH)+', PLEASE RE-ENTER"' ? ' CLEAR GETS' ? ' LOOP' ? ' ENDIF' ENDIF ENDIF SKIP ENDDO ? 'ENDIF' ? ' SET INTE ON' ? ' @ 23,50 SAY "ALL OK? (*=QUIT)" GET MOK PICT "!"' ? ' READ NOUP' ? ' SET INTE OFF' ? '* ----- END PROCESSING SECTION:' ? ? ' IF MOK="*"' ? ' CLEA' ? ' SET TALK ON' ? ' RETURN' ? ' ENDIF' ? ' IF MOK#"Y"' ? ' @ 23,0 SAY $(STR(0,80),1,79)' ? ' LOOP' ? ' ENDIF' ? ' CLEAR GETS' ? ' @ 23,0 SAY $(STR(0,80),1,79)' ? ' APPE BLANK' ? ' STOR mrecno+1 TO mrecno' * GENERATE REPLACE STATEMENTS ? '* ----- DATA BASE UPDATE SECTION:' GO TOP DO WHILE .NOT. EOF IF !(USED)='N'.OR.(FORMULA#' '.AND.FIELD:TYPE='N') IF !(USED)='N' .AND. FORMULA=' ' SKIP LOOP ELSE ? 'REPL '+TRIM(FIELD:NAME)+' WITH '+TRIM(FORMULA) SKIP LOOP ENDIF ENDIF DO CASE CASE FIELD:TYPE='C' IF !(ANS)='U' ? ' IF M'+TRIM(FIELD:NAME)+'#"_"' ? ' REPL '+TRIM(FIELD:NAME)+' WITH $(M'+TRIM(FIELD:NAME)+',1,@("_",M'+TRIM(FIELD:NAME)+')-1)' ? ' ELSE'  ? ' REPL '+TRIM(FIELD:NAME)+' WITH M'+TRIM(FIELD:NAME) ? ' ENDIF' ELSE ? ' REPL '+TRIM(FIELD:NAME)+' WITH M'+TRIM(FIELD:NAME) ENDIF CASE FIELD:TYPE='N' ? ' REPL '+TRIM(FIELD:NAME)+' WITH M'+TRIM(FIELD:NAME) CASE FIELD:TYPE='D' ? '* DATE FIELD REVERSAL AND COMPRESSION' ? ' REPL '+TRIM(FIELD:NAME)+' WITH $(M'+TRIM(FIELD:NAME)+',7,2)+$(M'+TRIM(FIELD:NAME)+',1,2)+$(M'+TRIM(FIELD:NAME)+',4,2)' ENDCASE IF !(INDEX)#'Y' ?? ' NOUP' ENDIF SKIP ENDDO * GENERATE AND HANDLE DEFAULTS AND CARRY FEATURES ? '* ----- MEMORY VARIABLE UPDATE SECTION:' ? GO TOP DO WHILE .NOT. EOF IF !(USED)='N' SKIP LOOP ENDIF IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' IF !(CARRY)='N'.OR.CARRY=' ' IF FIELD:LEN>FMAXLEN ? ' *** LONG FIELD NAME, SUBSTRING USED TO FIT' ? ' STOR $(MBL80,1,'+STR(FMAXLEN,3)+') TO M'+TRIM(FIELD:NAME) ELSE ? ' STOR $(MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(FIELD:NAME) ENDIF ENDIF IF DEFAULT#' ' ? ' STOR $("'+TRIM(DEFAULT)+'"+MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(FIELD:NAME) ENDIF ELSE IF DEFAULT#' ' ? ' STOR '+STR(VAL(DEFAULT),FIELD:LEN)+' TO M'+TRIM(FIELD:NAME) ELSE ? ' STOR 0 TO M'+TRIM(FIELD:NAME) ENDIF ENDIF SKIP ENDDO ? 'ENDDO' SET ALTE OFF SET ALTE TO set inde to DELE FILE SEQ.NDX SET TALK ON CLEA CANCEL TRIM(FIELD:NAME)+',4,2)' ENDCASE IF !(INDEX)#'Y' ?? ' NOUP' ENDIF SKIP ENDDO * GENERATE AND HANDLE DEFAULTS AND CARRY FEATURES ? '* ----- MEMORY VARIABLE UPDATE SECTION:' ? GO TOP DO WHILE .NOT. EOF IF !(USED)='N' SKIP LOOP ENDIF IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' IF !(CARRY)='N'.OR.CARRY=' ' IF FIELD:LEN>FMAXLEN ? ' *** LONG FIELD NAME, SUBSTRING USED TO FIT' ? ' STOR $(MBL80,1,'+STR(FMAXLEN,3)+') TO M'+TRIM(FIELD:NAME) ELSE ? ' STOR $(MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(FIELD:NAME) ENDIF ENDIF IF DEFAULT#' ' ? ' STOR $("'+TRIM(DEFAULT)+'"+MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(FIELD:NAME) ENdDOCUMENTATION FOR: - - d S C R E E N - - AN AUTOMATIC COMMAND FILE GENERATOR FOR dBASE II DATA ENTRY by Mark Scaramella Version 1.3 01/27/85 This file describes dSCREEN.CMD (.PRG), a command file generator which generates a dBASE II command file for data entry. As is the case with any such programming project, I have had some difficulty making this documentation keep up with the later features which were added to the program. I have attempted to maintain currency within the time available to me to work on this program. I apologize if the samples on this disk are not identical to the way the program currently runs. Hopefully, any such small differences will not affect normal use of the current version. I now have a greater appreciation for how hard it is to make documentation keep up with the product it describes. dINTRODUCTION: This program grew out of my own applications generation experience where I work. I have always found it annoying to do data entry screens because they seemed to change too often requiring a lot of tedious editing and re-testing to reflect the change. This program is an attempt to knock down some of these barriers, particularly for the simpler (and in my experience, more frequent) data entry situations. The program is unique in several respects: 1) It runs from within dBASE II - you do not have to exit dBASE to generate the command file. 2) It is "interactive". That is you get fairly quick feedback on how the program is going to work in the particular situation. You see it as it is generated. And you can make a trial run immediately after it is generated. If there are small problems, just edit the screen characteristics database and re-run. I think you will find this to be a real luxury. 3) It allows you to focus more on how the data is to be entered and not on what code is required or on some of the "difficulty trade off's". I find myself saying "Oh that method of data entry is too hard to code", or "Oops, forgot to picture a field", etc. It also provides for standardization of data entry and the associated logic. In addition, if you add features and "tweaks" to the program generator itself, you can use the program as a form of corporate memory for data entry. 4) It is database driven, not screen driven. You enter your screen characteristics into a specially set up database file which is used by the dSCREEN program to generate the command file, including the @ SAY's and @ GET's. I find this to be particularly useful and the primary reason that I wrote the program. You don't have to go through the process of "painting" the screen, which I consider to be tedious and unnecessarily difficult for a large number of data entry situations. 5) The program has some handy features which generate "pseudo- intelligent" data entry routines. These features include: - Field selectable carry forward of data to next record - Calculated Fields. You can specify a formula for generating calulated fields. Such fields are not used on the data entry screen, however. - Field definable default values to be pre-filled. - Selection of fields to be used in the particular data entry process (e.g. only those fields being entered at the particular time). - Definable high (maximum) and low (minimum) values, for character or numeric fields, which can also be used to require data to be entered in selected fields (non-blank/non- zero). - Required fields. Fields which cannot be blank/zero (character or number, as applicable) - Filled fields. Fields which must contain no blanks and be completely filled with characters (Character fields only). - Definable field prompts (called aliases) of up to 30 characters to replace the often cryptic field names. - Allows specification that selected fields are included in index files. Fields included in indexes are REPLACEd in the data base without the NOUPDATE command, while fields that are not included in indexes are REPLACEd in the data base with the NOUPDATE command to speed up input. NOTE: For users of dBASE II versions prior to 2.4, the resultant command file must be edited to remove the NOUP commands used with READ and REPL. SET DELETED ON in the environment section must be removed. You will also note that the CASE statement which checks for file names in dSCREEN does not seem to work in 2.3b. This may be a bug. It does seem to work as an IF statement. (?) - "Quasi"-Date Fields. If the word "DATE" is used in the field name or the alias, the field will be pictured as 99/99/99. Not a real date field, but it's handy. Date fields have their field types changed to 'D'. Such fields are stored in the data base in the form YYMMDD to save a little space and to make indexing or sorting easier. If you don't like this approach its fairly simple to modify the code to remove the date reversal logic since it is highlighted as such. - Selection of underlines in the data entry area instead of blanks. This is a cosmetic feature. It isn't standard, but works OK for character fields. Using underlines slows down the data entry process a little, and makes the command file which is generated longer. I suggest you experiment with this feature a little before you choose it for normal data entry. In particular, you shouldn't use underlines if you expect the underline character ("_") to be used in your data. - User definable centered screen heading. 6) The program uses the (somewhat) advanced technique of putting only the GETS in the data entry loop. This makes a cleaner and faster display. It is fairly tedious to do this for each new program if you have to write the program "the old- fashioned way", but much easier when done as part of a program like this. 7) EVERYTHING about the program is modifiable to suit your tastes and style of programming. Nothing is hidden. - You can modify the dSCREEN program itself so that it generates a different type of command file (if you figure out what's going on in the command file). - OR, you can modify the resultant command file which is generated if you need special characteristics. - You can also modify the generation process at several points which are mentioned as the program runs. Primarily you can edit the row and column positions and the sequences that the fields will appear on the screen by editing the screen characteristics file at the appropriate time. - You can modify the operating environment by adjusting the SET statement generation of the program to suit your own tastes. dLIMITATIONS: The program won't handle more than about 22 fields of data entry. It won't refuse to work if you tell it more than 22, but the screen will get messed up. I chose this (somewhat messy) method because you can still generate the code for more than 22 fields if you need to, and then modify the code if/as required to fit the screen. The program doesn't handle long fields. (over 50 or so characters long). I have found that this doesn't happen very often, and when it does, it is not practical to automate in a program like this anyway. The code that is generated flags fields that were truncated to fit so that you can make any modifications at that spot. The program doesn't do much error or logic checking... It, like dBASE itself, assumes you know what you are doing. If you find you need checking at certain points, feel free to add the appropriate code. I personally don't like too much checking, it slows things down. However, you do have to be a little careful in naming files. If you are, you will find it handy when it overwrites files which need to be replaced/fixed just by giving the same file name again. The program does not support logical fields. If your application requires logical fields you have three choices: 1) Change them to 1 or 2 character character fields, 2) modify the command file that is generated to support your logical fields, or 3) wait until a later version of dSCREEN which may support logical fields. The program flags logical fields at the beginning of the command file and leaves space on the screen for them. You can use the command file comments for each section of the code to determine where any updates may be required in the code for logical fields. I have tested the program a fair amount, but I cannot say that I have tried every conceivable combination of things. One thing to avoid in entering screen characteristics would be single quotes and double quotes. If you look at the program you will see why I make this suggestion. It builds statements with single and double quotes and it would probably get confused if it saw either type of quote in a statement if it wasn't part of the original statement. Be sure to read the notes/comments at the beginning of the program for other information regarding use of the program. RUNNING dPROGRAM: Running the program is in three major steps with stopping points at selected spots along the way in the third step. The first step sets up the database file with the fields where you enter the screen characteristics. You have to generate the basic (empty) file XSCREEN(.dbf) first (if it's not already on the disk you are using/copied) and keep it together with dSCREEN. See the command file for details. The second step is editing the screen characteristics database file with your selections. The third step is actual command file generation. This step has two parts: 1) Field characteristics generation (which can be skipped if you have entered your own sequence, row, and column position data. 2) Command file generation The command file generation is performed with SET ALTERNATE. If you hit escape or if errors are encountered which force you to stop the command file generation, don't forget that alternate has been turned on. dSAMPLE RUN [The following is a sample run of the program for a typical application/session. Comments and information unique to this documentation are inside of square brackets and set off in narrow margins. Like this.] DO DSCREEN (P)revious or (N)ew Screen Data Base Definition File ? WAITING N [Enter N (for new) if you want to generate an empty database for new screen characteristics] Enter database source file name :MAILLIST [Enter the database file name which will be used for data entry] [In this case I entered MAILLIST which is a typical customer mail list application with some extra fields for demonstration purposes.] [The file structure of MAILLIST is a follows:] [ . list stru] [STRUCTURE FOR FILE: D:MAILLIST.DBF NUMBER OF RECORDS: 00000 DATE OF LAST UPDATE: 12/19/84 PRIMARY USE DATABASE FLD NAME TYPE WIDTH DEC 001 CNAME C 030 002 ADDRESS1 C 030 003 ADDRESS2 C 030 004 CITY C 020 005 STATE C 002 006 ZIP C 010 007 PHONE1 C 014 008 PHONE2 C 014 009 CONTACT1 C 040 010 CONTACT2 C 040 011 COMMENT1 C 040 012 COMMENT2 C 040 013 COMMENT3 C 040 014 PRODCODE C 020 015 AMOUNT N 010 002 016 AMTAX N 010 002 017 DUEDATE C 008 018 REMARKS C 040 ** TOTAL ** 00439 Enter screen database file name to be created (Default: &dbscreen) :MAILSCR [Enter the name of the database where your screen characteristics data will be entered/found] MAILSCR file created. You may now edit MAILSCR (which is in use now) with your screen characteristics. Re-start this Program after editing. Use MAILSCR as the "(P)revious" file when prompted. DO CANCELLED [Now let's look at the structure of the file MAILSCR which was just created (The key to the whole idea here)...] FILE NAME: MAILSCR.DBF - SAMPLE CUSTOMER MAILING/CONTACT LIST FOR dSCREEN DOCUMENTATION INDEX(ES) and COMMENTS: DEMO PURPOSES ONLY |========================================================================| |FIELD| NAME |TYP|WIDTH|DEC| DESCRIPTION | |========================================================================| | | | | | | | | 1 |FIELD:NAME| C | 10 | | Field Name as obtained from the database| | | | | | | source file | |-----|----------|---|-----|---|-----------------------------------------| | 2 |ALIAS | C | 30 | | Field Alias for screen display | | | | | | | [Entered by User] | |-----|----------|---|-----|---|-----------------------------------------| | 3 |FIELD:TYPE| C | 1 | | Field Type as obtained from the database| | | | | | | source file | |-----|----------|---|-----|---|-----------------------------------------| | 4 |FIELD:LEN | N | 3 | 0| Field Length as obtained from the data | | | | | | | base source file | |-----|----------|---|-----|---|-----------------------------------------| | 5 |FIELD:DEC | N | 3 | 0| Field Decimals as obtained from the data| | | | | | | base source file | |-----|----------|---|-----|---|-----------------------------------------| | 6 |SEQUENCE | N | 2 | 0| Sequence of field on screen | | | | | | | [Default=Rec. No. OR User entered] | |-----|----------|---|-----|---|-----------------------------------------| | 7 |ROW | N | 2 | 0| Row on which Field is displayed | | | | | | | [Default=Sequence OR User entered] | |-----|----------|---|-----|---|-----------------------------------------| | 8 |ACOL | N | 3 | 0| Alias Column Position | | | | | | | [Default=1 OR User entered] | |-----|----------|---|-----|---|-----------------------------------------| | 9 |FCOL | N | 3 | 0| Field Column position | | | | |  | | [Default=Max Alias Width+2 OR User | | | | | | | entered] | |-----|----------|---|-----|---|-----------------------------------------| | 10 |CARRY | C | 2 | | Whether this field should be carried Y/N| | | | | | | [User entered] | |-----|----------|---|-----|---|-----------------------------------------| | 11 |DEFAULT | C | 50 | | Literal Default Entry for the field | | | | | | | [User entered] | |-----|----------|---|-----|---|-----------------------------------------| | 12 |PICTURE | C | 50 | | Picture for field (See dBASE Manual for | | | | | | | additional info on PICTURE) | | | | | | | [User entered] | |-----|----------|---|-----|---|-----------------------------------------| | 13 |REQD | C | 2 | | Whether this field is a required entry | | | | | | | [User entered] [Y/N] | |-----|----------|---|-----|---|-----------------------------------------| | 14 |FILL | C | 2 | | Whether all positions of this | | | | | | | field must have characters | | | | | | | [User entered] [Y/N] | |-----|----------|---|-----|---|-----------------------------------------| | 15 |HIGH | C | 10 | | Highest value allowed in field | | | | | | | [User entered] | |-----|----------|---|-----|---|-----------------------------------------| | 16 |LOW | C | 10 | | Lowest value allowed in field | | | | | | | [User entered] | |-----|----------|---|-----|---|-----------------------------------------| | 17 |FORMULA | C | 50 | | Formula for calculated fields, only  | | | | | | | applicable to numeric fields. | | | | | | | [User entered] | |-----|----------|---|-----|---|-----------------------------------------| | 18 |INDEX | C | 2 | | Whether this field is part of an index | | | | | | | [User entered] [Y/N] | |-----|----------|---|-----|---|-----------------------------------------| | 19 |USED | C | 2 | | Whether this field is to be used | | | | | | | [User entered] [Y/N] | |========================================================================| 234 Total characters in each record (including *) [There are seventeen records in this file. One record for each field in MAILSCR.DBF.] dSCREEN DATABASE EDITING: [Now that MAILSCR has been created, you can use the dBASE EDIT function to go into the file and enter the screen characteristics. I find this to be the simplest method. I suppose you could make this sexier, but I don't think it would add anything.] [Here are some of the records and edits to show typical entries and comments. Notice that all of the SEQUENCE Fields are the same as the record number. This is the default, however, you can change the sequence, row and column positions and run the program accordingly.] RECORD # 00001 FIELD:NAME:CNAME : ALIAS : : FIELD:TYPE:C: FIELD:LEN : 30: FIELD:DEC : 0: SEQUENCE : 1: ROW : : ACOL : : FCOL : : CARRY : : DEFAULT : : PICTURE : : REQD : : FILL : : HIGH : : LOW : : FORMULA :  : INDEX : : USED : : [This first record is the customer name field. This is how it looks before editing. Since it is a simple field, only an alias is entered. It is also a required field.] RECORD # 00001 FIELD:NAME:CNAME : ALIAS :Customer Name : FIELD:TYPE:C: FIELD:LEN : 30: FIELD:DEC : 0: SEQUENCE : 1: ROW : 3: ACOL : 1: FCOL : 15: CARRY : : DEFAULT : : PICTURE : : REQD :Y : FILL : : HIGH : : LOW : : FORMULA : : INDEX :Y : USED : : [In general a blank entry or an "N" have the same effect for Yes/No Questions. For the other features (where what is entered is used in the command file) any entry is taken literally. I have also selected this field as a field included in an index.] RECORD # 00004 FIELD:NAME:CITY : ALIAS :City : FIELD:TYPE:C: FIELD:LEN : 20: FIELD:DEC : 0: SEQUENCE : 4: ROW : 6: ACOL : 1: FCOL : 15: CARRY :Y : DEFAULT : : PICTURE : : REQD :Y : FILL : : HIGH : : LOW : : FORMULA : : INDEX : : USED : : [In this case an alias is entered and I selected carry for this field because I expect that a lot of items to be entered will be from the same city and that they will be grouped for entry by city (to some extent). I also selected this field as required.] RECORD # 00005 FIELD:NAME:STATE : ALIAS  :State : FIELD:TYPE:C: FIELD:LEN : 2: FIELD:DEC : 0: SEQUENCE : 5: ROW : 7: ACOL : 1: FCOL : 15: CARRY : : DEFAULT :CA : PICTURE :AA : REQD :Y : FILL : : HIGH : : LOW : : FORMULA : : INDEX : : USED : : [For the STATE field I entered the ALIAS (required if you want any prompt at all) and a default value of CA. In addition I only want letters of the alphabet in State to prevent accidental errors of number so I pictured this field as AA. Also a required field.] RECORD # 00008 FIELD:NAME:PHONE2 : ALIAS :Alternate Phone : FIELD:TYPE:C: FIELD:LEN : 14: FIELD:DEC : 0: SEQUENCE : 8: ROW :10: ACOL : 1: FCOL : 15: CARRY  : : DEFAULT : : PICTURE :(999) 999-9999 : REQD : : FILL : : HIGH : : LOW : : FORMULA : : INDEX : : USED : : [For the PHONE2 FIELD I selected a better field alias and pictured the phone number for all numerics and the standard phone number format.] RECORD # 00015 FIELD:NAME:REMARKS : ALIAS : : FIELD:TYPE:C: FIELD:LEN : 40: FIELD:DEC : 0: SEQUENCE :15: ROW : 0: ACOL : 1: FCOL : 0: CARRY : : DEFAULT : : PICTURE : : REQD : : FILL : : HIGH : : LOW : : FORMULA : : INDEX : : USED :N :  [The REMARKS field is not going to be used for data entry at this time so I said "N" for USED.] RECORD # 00013 FIELD:NAME:AMOUNT : ALIAS :Amount Sold : FIELD:TYPE:N: FIELD:LEN : 10: FIELD:DEC : 2: SEQUENCE :13: ROW :15: ACOL : 1: FCOL : 15: CARRY : : DEFAULT : : PICTURE : : FILL : : REQD :y : HIGH : : LOW :1 : FORMULA : : INDEX : : USED : : Amount is used here just for demo purposes to include a numeric field. I also chose not to allow any entries less than 1 and made it a required field. RECORD # 00014 FIELD:NAME:AMTAX : ALIAS : : FIELD:TYPE:N: FIELD:LEN : 10: FIELD:DEC : 2: SEQUENCE :14: ROW :16: ACOL : 1: FCOL : 15: CARRY : : DEFAULT : : PICTURE : : REQD : : FILL : : HIGH : : LOW : : FORMULA :AMOUNT*1.065 : INDEX : : USED :N : This is an example of a calculated field. A formula is entered as shown. No checking is done by this program for valid formulas. If you enter an invalid formula, you will get an error when you try to run the command file that is generated. Note that this field is NOT used - That is it is not shown on the data entry screen that is generated. RECORD # 00016 FIELD:NAME:DUEDATE : ALIAS :Order due date : FIELD:TYPE:C: FIELD:LEN : 8: FIELD:DEC : 0: SEQUENCE :16: ROW :16: ACOL : 1: FCOL : 15: CARRY : : DEFAULT : : PICTURE :99/99/99 : REQD :y : FILL :y : HIGH : : LOW : : FORMULA : : INDEX : : USED : : This is included as an example of what happens when the word "DATE" is used in a field name or an alias. The program simply pictures the field as 99/99/99. I also chose to require this field to be filled. [Here are the raw contents of MAILSCR.DBF after I edited the file with my screen characteristics data. The list extends to column 270 or so, use editor to see all of the data.] . list FIELD: FIELD: FIELD: Carry Fill REC# NAME ALIAS TYPE WIDTH DEC SEQ Row ACol Fcol Default Picture Reqd High Low Formula Used 00001 CNAME Customer Name C 30 0 1 3 1 15 Y 00002 ADDRESS1 Address #1 C 30 0 2 4 1 15 Y 00003 ADDRESS2 Address #2 C 30 0 3 5 1 15 00004 CITY City C 20 0 4 6 1 15 Y 00005 STATE State C 2 0 5 7 1 15 CA AA  Y 00006 ZIP Zip Code C 10 0 6 8 1 15 y 99999-9999 Y 00007 PHONE1 Phone No. 1 C 14 0 7 9 1 15 (415) (999) 999-9999 00008 PHONE2 Alternate Phone C 14 0 8 10 1 15 (999) 999-9999 00009 CONTACT1 Contact(s) C 40 0 9 11 1 15 00010 CONTACT2 Contact(s) C 40 0 10 12 1 15 00011 COMMENT1 Comments C 40 0 11 13 1 15 00012 COMMENT2 . C 40 0 12 14 1 15 00013 AMOUNT Amount Sold N 10 2 13 15 1 15  y 1 00014 AMTAX N 10 2 14 16 1 15 AMOUNT*1.065 N 00015 REMARKS C 40 0 15 0 1 0 N 00016 DUEDATE Order due date C 8 0 16 16 1 15 99/99/99 Y [Now that editing is complete, re-start the program to finish the process.] . do DSCREEN - - d S C R E E N - - AN AUTOMATIC COMMAND FILE GENERATOR FOR dBASE II DATA ENTRY by Mark Scaramella Version 1.3 12/30/84 (P)revious or (N)ew Screen Data Base Definition File ? WAITING P [Now we answer "P" since we already have the screen characteristics file previously entered.] Screen database file with your screen characteristics (Default type .DBS) :MAILSCR [And enter the file with the screen characteristics.] Enter Screen Heading:CUSTOMER DATABASE DATA ENTRY SCREEN [Entry of screen heading... Space permitting.] Command file only? (Say yes at this point if you have entered your own field sequence, row, and column positions into the screen database file) WAITING N [We want the program to go ahead and generate the sequence, row and column positions.] Field characteristics generation complete. Do you want to continue with command file generation? (Stopping now and restarting later will allow manual editing of alias and field screen characteristics before re-starting WAITING Y [Of course, go ahead. We do not want to stop and edit the sequence row or column positions.] Name of command file to be generated:MAILENT [To generate MAILENT.CMD or PRG ] Name of database file to be used? :MAILLIST Name index file(s) to be used (separated by commas) if applicable :CNAME [This is the database and index files which the command file will "USE". Normally, the database is the same as the "SOURCE FILE" entered above.] Fill field entry area with (B)lanks or (U)nderlines ? WAITING B [Here is where you pick Blanks or Underlines for the data entry area.] [At this point the program should charge off and generate the command file. You will see it go by on the screen. You can usually tell if things are what you expected or not. Feel free to stop the program if you need to and re-  start. Remember that ALTERNATE is ON. This is not a problem most of the time, since the CMD/PRG file being generated will simply be written over when you re-start and any junk at the end of the old version will automatically disappear.] The command file which was generated for this sample application is on the disk as a separate file. You have the choice of immediately running what the program generates, or editing it before running. I generally prefer running it first. Of course, things have to be minimally set-up to run it: the database file which you told it to use should be present, etc. Future versions may contain built-in file existence checks. Depends on feedback and donations. I am also considering the addition of a table lookup function limited to one field in the database. Also depends on feedback and donations. After the command file is generated, you can immediately say "DO xxxxxxxxx" (whatever you named it) Here is what the command file generated above generates as a blank entry screen. CUSTOMER DATABASE DATA ENTRY SCREEN =============================================================================== Customer Name...: Address #1......: Address #2......: City............: State...........:CA Zip Code........: - Phone No. 1.....:(415) - Alternate Phone.:( ) - Contact(s)......: Contact(s)......: Comments........: ......: Amount Sold.....: 0 Order due date..: / / and here is a typical entry. CUSTOMER DATABASE DATA ENTRY SCREEN =============================================================================== Customer Name...:ABC ELECTRONICS =============================================================================== Address #1......:909 WEST THIRD AVE.  REC NO: 1 Address #2......:SUITE 10 City............:SAN FRANCISISCO State...........:CA Zip Code........:91234-0000 Phone No. 1.....:(415) 555-1212 Alternate Phone.:( ) - Contact(s)......:NORM NORMANS Contact(s)......:JOE JOSEPH Comments........:WANTS MORE DATA ABOUT SYSTEM ......: Amount Sold.....: 12 Order due date..:09/09/85 =============================================================================== ALL OK? (*=QUIT) and here is the next record with the carry of CITY and ZIP CODE, and default of CA as STATE CUSTOMER DATABASE DATA ENTRY SCREEN =============================================================================== Customer Name...: Address #1......: Address #2......: City............:SAN FRANCISCO State...........:CA Zip Code........:91234-0000 Phone No. 1.....:(415) - Alternate Phone.:( ) - Contact(s)......: Contact(s)......: Comments........: ......: Amount Sold.....: 0 Order due date..: / / =============================================================================== REC NO: 2 and here is a case where I tried to enter 0 for the amount, and got the appropriate error message. CUSTOMER DATABASE DATA ENTRY SCREEN =============================================================================== Customer Name...:HARBINGER THINGS Address #1......:909 HOTEL AVE. Address #2......: City............:SAN FRANCISCO State...........:CA Zip Code........:91234-0000 Phone No. 1.....:(415) - Alternate Phone.:( ) - Contact(s)......:RACHEL WARDEN Contact(s)......: Comments........: ......: Amount Sold.....: 0 Order due date..:10/10/85 =============================================================================== Amount Sold IS A REQUIRED ENTRY, PLEASE RE-ENTER REC NO: 2 Here is the raw record which was entered as record no. 1. Notice that the AMTAX field has been calculated as 12.78. . USE MAILLIST . LIST 00001 ABC ELECTRONICS 909 WEST THIRD AVE. SUITE 10 SAN FRANCISISCO CA 91234-0000 (415) 555-1212 ( ) - NORM NORMANS JOE JOSEPH WANTS MORE DATA ABOUT SYSTEM 12. 00 12.78 09/09/85 dEND I hope that you find this program useful and helpful. As mentioned in the program, I will entertain written comments, requests, bugs, enhancements, errors, etc. Since this program provides a nice framework (no reference to any other software intended) for adding features, I will probably be issuing updates as mentioned above depending on how things go. As I hope you can tell, this program and the associated documentation was no small task to conceive and develop. I am releasing the program to the public domain. I specifically prohibit any selling, or commercial trading of the concept or implementation of this idea, and would appreciate anyone informing me if they notice such commercialization. Feel free to make copies for yourself or friends or any other non-commercial use. If you find dSCREEN helpful and would like to contribute to its further growth, please send a donation of $20.00 or so (less than the price of a decent dBASE II book minus tax, which this also represents) to: Mark Scaramella c/o ESD Corporation 600 Meridian Ave. San Jose, CA 95126 Thanks. Happy Data Entry.... *********************************************************************** * Program Name.........: dSCREEN.CMD/PRG * Purpose..............: DATA ENTRY SCREEN CODE GENERATOR FOR dBASE II * Author...............: MARK C. SCARAMELLA * * ==================================================================== * * Copyright Notice.....: Copyright (C) 1984, Mark C. Scaramella * All rights reserved * Released to the Public Domain * Not for resale without the explicit permission * of the author. Modifications for personal * use are authorized and encouraged. * Please notify author of any improvements or * fixes implemented or requested at: * * Mark C. Scaramella * c/o ESD Corporation * 600 Meridian Ave. * San Jose, CA 95126 * *  Telephone calls cannot be responded to, * Letters only please. * * If you like dSCREEN and find it helpful and * you would like to contribute to its "growth and * development", please send a donation of $20.00 * (or more) to the above address. * * ======================================================================= * * Date................: 1/27/85 * Version.............: 1.3 with high/low exclusion * Date Fields,Req'd Fields,Calc Fields,Heading * Date Reversal/Compression,Index Files,NOUP * dBASE II Version....: 2.4 and up. Should work with 2.3b, but not * thoroughly tested under 2.3b (must remove NOUP * command, SET DELETED ON command, must remark out/ * remove CASE statements which test for files. or * re-write them as IF statements which seem to work.) * Updates under consideration: * - Automatic Table lookup * - Automatic Field/File Name validity checking * in output command file. * - Logical Field Support * Comment/Notes.......: - Picture Clause and numeric fields don't * work with underlines * - Logical Field Types are not supported * (Logical Fields will be flagged.) * - Field Sequence defaults to record number * - No checking for file existence except at * start up. This allows for automatic write- * over of command files during generation. * - Generator gets confused by 10 character * field names becuase of "M" added for memory * variables. Avoid 10 character field names *  or... modify the command file output. ************************************************************************ set talk off erase ? ? ? ? ' - - d S C R E E N - -' ? ? ' AN AUTOMATIC COMMAND FILE GENERATOR FOR dBASE II DATA ENTRY' ? ? ' by Mark Scaramella' ? ? ' Version 1.3 01/27/85' ? ? ? if .not. file('XSCREEN.dbf') ? CHR(7)+'Sorry, XSCREEN.DBF must be on the default disk for this program to run.' ? 'See program documentation/comments for details.' ? 'Re-start when XSCREEN.DBF is set up.' cancel endif ? '(P)revious or (N)ew Screen Data Base Definition File ? ' wait to ans if !(ans)='N' * STEP ONE: MAKE A DATABASE FILE FROM THE STRUCTURE OF THE SOURCE * FILE USING THE PREVIOUSLY DEFINED FILE: XSCREEN.DBF WITH THE * FOLLOWING CHARACTERISTICS: * *STRUCTURE FOR FILE: D:XSCREEN .DBF *NUMBER OF RECORDS: 00000 *DATE OF LAST UPDATE: 01/27/85 *PRIMARY USE DATABASE *FLD NAME TYPE WIDTH DEC *001 FIELD:NAME C 010 *002 ALIAS C 030 *003 FIELD:TYPE C 002 *004 FIELD:LEN N 003 *005 FIELD:DEC N 003 *006 SEQUENCE N 002 *007 ROW N 002 *008 ACOL N 003 *009 FCOL N 003 *010 CARRY C 002 *011 DEFAULT C 050 *012 PICTURE C 050 *013 REQD C 002 *014 FILL C 002 *015 HIGH C 010 *016 LOW C 010 *017 FORMULA C 050 *018 INDEX C 002 *019 USED C 002 *** TOTAL ** 00239 ACCEPT "Enter database source file name " to dbfile stor !(trim(dbfile)) to dbfile DO CASE CASE DBFILE = " " cancel * CASE .NOT. FILE("&DBFILE") * ? CHR(7)+"FILE DOES NOT EXIST (on this drive)" * ? "Please re-start." * cancel ENDCASE use &dbfile copy stru exte to stemp use xscreen if "."$dbfile stor !($(dbfile,1,@(".",dbfile))+"dbs") TO dbscreen else stor !(dbfile+".dbs") TO dbscreen ENDIF acce 'Enter screen database file name to be created (Default: &dbscreen) ' to dbscrn if dbscrn#" " stor dbscrn to dbscreen endif copy stru to &dbscreen use &dbscreen appe from stemp repl all sequence with # dele file stemp ? ? '&dbscreen file created. You may now edit &dbscreen (which is' ? 'in use now) with your screen characteristics. Re-start this' ? 'Program after editing. Use &dbscreen as the "(P)revious" file' ? 'when prompted.' cancel else IF FILE("dscreen.cmd") STOR "CMD" TO mtyp ELSE STOR "PRG" TO mtyp ENDIF * STEP TWO: * SCREEN DATABASE FILE ALREADY EXISTS AND EDITED, READY FOR PROCESSING ? 'Screen database file with your screen characteristics (Default type .DBS) ' ACCE TO scrfile IF .NOT."."$scrfile STOR scrfile+".DBS" TO scrfile ENDIF DO CASE CASE SCRFILE = " " cancel * CASE .NOT. FILE("&SCRFILE") * ? CHR(7)+"FILE DOES NOT EXIST (on this drive)" * ? "Please re-start." * cancel ENDCASE use &scrfile endif go bott stor $(str(0,81),1,80) to mbl if #<20 ACCE 'Enter Screen Heading ' to mshead stor $(mbl,1,(80-len(trim(mshead)))/2)+mshead to mshead else stor 'X' to mshead endif if #>22 ? ? '*** More than 22 fields in screen database, some command file' ? 'modification will be required after it is generated.' ? endif * SEE IF USER HAS OVERRIDDEN @SAY/@GET POSITIONS IN THE SCREEN DATABASE ? ? 'Command file only?' ? ? '(Say yes at this point if you have entered new row' ? 'and column positions into the screen database file)' ? wait to mcmdans if !(mcmdans)="N" repl all acol with 1 * DETERMINE WIDEST FIELD ALIAS NAME INDE ON 100-LEN(TRIM(ALIAS)) TO ALEN GO TOP * IGNORE UNUSED FIELDS DO WHILE !(USED)='N' SKIP ENDDO STOR LEN(TRIM(ALIAS)) TO AMAXLEN STOR 77-AMAXLEN TO FMAXLEN set inde to DELE FILE ALEN.NDX repl all used with 'N' for formula#' ' INDE ON SEQUENCE TO SEQ GO TOP STOR 1 TO MCOL if mshead='X' stor 1 to mrow else stor 3 to mrow endif * FIRST LOOP CALCULATES ROW/COL POSITIONS AND CHECKS FOR DATE FIELDS DO WHILE .NOT. EOF IF !(USED)='N' SKIP LOOP ENDIF IF 'DATE'$!(FIELD:NAME).OR.'DATE'$!(ALIAS) repl field:type with 'D' REPL PICTURE WITH '99/99/99' ENDIF STOR LEN(TRIM(ALIAS))+FIELD:LEN TO TLEN REPL ROW WITH MROW,ACOL WITH MCOL REPL FCOL WITH AMAXLEN+1 STOR MROW+1 TO MROW SKIP ENDDO ? ? 'Field characteristics generation complete.' ? ? 'Do you want to continue with command file generation?' ? ? '(Stopping now and restarting later will allow manual editing' ? 'of alias and field screen characteristics before re-starting.)' ? wait to ans if !(ans)='N' cancel endif endif * NOW GENERATE THE COMMAND FILE * DETERMINE THE WIDEST FIELD ALIAS NAME INDE ON 100-LEN(TRIM(ALIAS)) TO ALEN GO TOP DO WHILE !(USED)='N' SKIP ENDDO STOR LEN(TRIM(ALIAS)) TO AMAXLEN STOR 77-AMAXLEN TO FMAXLEN set inde to DELE FILE ALEN.NDX INDE ON SEQUENCE TO SEQ GO TOP ACCE 'Name of command file to be generated ' to cmdfile ? acce 'Name of database file to be used ' TO mdbf ? 'Name index file(s) to be used (separated by commas) if applicable' acce TO mndx ? ? 'Fill field entry area with (B)lanks or (U)nderlines ? ' wait to ans IF .NOT."."$cmdfile STOR CMDFILE+'.'+MTYP TO CMDFILE ENDIF set alte to &cmdfile set alte on Stor '...................................................' to mdots go top * GENERATE DRAFT PROGRAM DOCUMENTATION ? '***********************************************************************' ? '* Program Name.....: '+cmdfile ? '* Purpose..........: Data Entry For '+MDBF IF mndx#" " ?? 'Index &mndx' ENDIF ? '* Author...........: Your Name' ? '* Copyright Notice.: Copyright (C) 1985, Your Name, All rights reserved' ? '* Date.............: '+date() ? '* dBASE II version.: 2.4x' ? '* CMD file version : 1.0' ? '* Memory Variables.: "M"+Field names + control variables +...?' ? '* Comments/Notes...:  ' ? '* : ' ? '***********************************************************************' * SET "SETS" TO YOUR OWN TASTE ? '* ---- ENVIRONMENT SECTION:' ? ? '* Reset dBASE II with no active data bases and no memory variables' ? 'CLEAR' ? 'SET STEP OFF ".......... Obviously."' ? 'SET PRINT OFF "......... Obviously."' ? 'SET ECHO OFF ".......... Obviously (unless you want to see commands)"' ? 'SET TALK OFF ".......... Obviously (unless you want to see calculations)"' ? 'SET ALTERNATE OFF "..... Obviously."' ? 'SET ALTERNATE TO' ? 'SET BELL OFF ".......... Obviously. The Bell implementation is useless"' ? 'SET CARRY OFF "......... This seems like a good default state"' ? 'SET COLON ON ".......... Important. Not every screen has intensity"' ? 'SET CONFIRM OFF "....... Optional. You may want to default to ON."' ? 'SET CONSOLE ON "........ Obviously."' ? 'SET DEBUG OFF "......... Obviously."' *? 'SET DELETED ON "........ Optional. ON prevents DELETEd records from being"' ? '* included in a command with a scope (v. 2.4 only)' ? 'SET EJECT OFF "......... This eliminates Ejects before printout and"' ? '* requires an EJECT at the completion of a printout' ? 'SET ESCAPE OFF "........ Optional. You may want to run with ESCAPE ON"' ? 'SET EXACT OFF "......... Optional (though usual default is OFF)"' ? 'SET FORMAT TO SCREEN ".. Obviously."' ? 'SET INTENSITY OFF "..... Different screens have different ways of"' ? '* presenting intensity. It is good to start with' ? '* it off and control it.' ? 'SET LINKAGE OFF "....... Obviously."' ? 'SET RAW ON "............ Optional (though this is a good default position"' ? '* to prevent problems with semi-colons)' ? 'SET SCREEN ON "......... Obviously."' ? 'ERASE "................. Clear the screen"' ? ? '* Put 79 blanks in a global memory variable' ? 'STORE $(STR(0,80),1,79) TO gmbl' ? ? 'USE &mdbf' IF !(ANS)='U' ? 'STOR "_____________________________________________________________" TO MBL80' ELSE ? '* ---- MEMORY VARIABLE INITIALIZATION:' ? ? 'STOR $(STR(0,81),1,80) TO MBL80' ENDIF DO WHILE .NOT. EOF if !(FIELD:TYPE)='L' ? '*** Logical Field types not yet supported, CMD/PRG file editing required' ? '*** Logical Field Name: '+Field:name REPL USED WITH 'N' endif IF !(USED)='N' SKIP LOOP ENDIF * SET UP DEFAULTS AND INITIALIZE VARIABLES DO CASE CASE FIELD:TYPE='C' * TRUNCATE VERY LONG FIELDS, TOO HARD TO HANDLE IN THIS SYSTEM * IF LONG FIELDS ARE REQUIRED, USE EDITOR ON COMMAND FILE AFTER * SUCCESSFUL CREATION/TEST. IF FIELD:LEN>FMAXLEN IF DEFAULT=' ' ? '*** LONG FIELD NAME, SUBSTRING USED TO FIT' ? 'STOR $(MBL80,1,'+STR(FMAXLEN,3)+') TO M'+TRIM(field:name) ELSE ? '*** LONG FIELD NAME, SUBSTRING USED TO FIT' ? 'STOR $("'+TRIM(DEFAULT)+'"+MBL80,1,'+STR(FMAXLEN,3)+') TO M'+TRIM(field:name) ENDIF ELSE IF DEFAULT=' ' ? 'STOR $(MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(field:name) ELSE ? 'STOR $("'+TRIM(DEFAULT)+'"+MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(field:name) ENDIF ENDIF CASE FIELD:TYPE='N' IF VAL(DEFAULT)=0 ? 'STOR 0 TO M'+TRIM(field:name) ELSE ? 'STOR '+trim(DEFAULT)+' TO M'+TRIM(field:name) ENDIF CASE FIELD:TYPE='D' IF DEFAULT=' ' ? 'STOR $(MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(field:name) ELSE ? 'STOR $("'+TRIM(DEFAULT)+'"+MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(field:name) ENDIF ENDCASE SKIP ENDDO GO TOP ? '* ----- SCREEN FORMAT INITIALIZATION:' ? ? 'ERASE' * GENERATE @SAYS ONE TIME BEFORE STARTING GET LOOP ? 'SET INTE ON' DO WHILE .NOT. EOF IF !(USED)='N' SKIP LOOP ENDIF IF FCOL<=31 ? '@ '+STR(ROW,2)+', '+STR(ACOL,2)+' SAY "'+$(TRIM(ALIAS)+MDOTS,1,FCOL)+':"' ELSE ? '@ '+STR(ROW,2)+', '+STR(ACOL,2)+' SAY "'+$(TRIM(ALIAS)+MDOTS,1,LEN(TRIM(ALIAS))+2)+':"' ENDIF SKIP ENDDO * GENERATE LOOP START-UP STATEMENTS ? 'SET INTE OFF' ? ? 'GO BOTT' ? 'STOR #+1 TO MRECNO' IF mndx#" " ? 'SET INDEX TO &mndx' ENDIF ? 'STOR " " TO MOK' ? 'DO WHILE T' ? ' @ 23,68 SAY "REC NO:"+STR(MRECNO,4)' if mshead#'X' ? '@ 1,1 say "&mshead"' ? '@ 2,1 say "==============================================================================="' ? '@ 22,1 say "==============================================================================="' endif * GENERATE @GETS/PICTURES ? '* ----- DATA INPUT SECTION:' ? GO TOP ? 'SET INTE ON' DO WHILE .NOT. EOF IF !(USED)='N' SKIP LOOP ENDIF IF PICTURE=' ' ? ' @ '+STR(ROW,2)+', '+STR(FCOL+2,2)+' GET M'+TRIM(field:name) ELSE ? ' @ '+STR(ROW,2)+', '+STR(FCOL+2,2)+' GET M'+TRIM(field:name)+' PICT '+'"'+!(TRIM(PICTURE))+'"' ENDIF SKIP ENDDO * GENERATE READ AND END LOGIC GO TOP ? ' READ ' ? 'SET INTE OFF' ? ' @ 23,0 SAY $(STR(0,80),1,79)' * GENERATE REQUIRED FIELD LOGIC ? '* ----- DATA VALIDATION SECTION:' ? GO TOP IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF M'+TRIM(field:name)+' # " "' ELSE ? ' IF M'+TRIM(field:name)+'>0' ENDIF DO WHILE .NOT. EOF IF !(REQD)='Y' IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF M'+TRIM(FIELD:NAME)+' = " "' ELSE ? ' IF M'+TRIM(FIELD:NAME)+' = 0' ENDIF ? ' @ 23,10 SAY CHR(7)' ? ' @ 23,10 SAY "'+TRIM(ALIAS)+' IS A REQUIRED ENTRY, PLEASE RE-ENTER"' ? ' CLEAR GETS' ? ' LOOP' ? ' ENDIF' ENDIF IF !(FILL)='Y' IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF " "$M'+TRIM(FIELD:NAME) ? ' @ 23,10 SAY CHR(7)' ? ' @ 23,10 SAY "'+TRIM(ALIAS)+' MUST BE COMPLETELY FILLED, PLEASE RE-ENTER"' ? ' CLEAR GETS' ? ' LOOP' ? ' ENDIF' ENDIF ENDIF SKIP ENDDO * GENERATE HIGH AND LOW LIMIT LOGIC GO TOP DO WHILE .NOT. EOF IF HIGH=' '.AND.LOW=' ' SKIP LOOP ENDIF IF HIGH=' '.AND.LOW#' ' IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF M'+TRIM(FIELD:NAME)+' < "'+TRIM(LOW)+'"' ELSE ? ' IF M'+TRIM(FIELD:NAME)+' < '+TRIM(LOW) ENDIF ? ' @ 23,10 SAY CHR(7)' ? ' @ 23,10 SAY "'+TRIM(ALIAS)+' CANNOT BE BELOW '+TRIM(LOW)+', PLEASE RE-ENTER"' ? ' CLEAR GETS' ? ' LOOP' ? ' ENDIF' ELSE IF HIGH#' '.AND.LOW=' ' IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF M'+TRIM(FIELD:NAME)+' > "'+TRIM(HIGH)+'"' ELSE ? ' IF M'+TRIM(FIELD:NAME)+' > '+TRIM(HIGH) ENDIF ? ' @ 23,10 SAY CHR(7)' ? ' @ 23,10 SAY "'+TRIM(ALIAS)+' CANNOT BE ABOVE '+TRIM(HIGH)+', PLEASE RE-ENTER"' ? ' CLEAR GETS' ? ' LOOP' ? ' ENDIF' ELSE IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF M'+TRIM(FIELD:NAME)+' < "'+TRIM(LOW)+'"' ELSE ? ' IF M'+TRIM(FIELD:NAME)+' < '+TRIM(LOW) ENDIF ? ' @ 23,10 SAY CHR(7)' ? ' @ 23,10 SAY "'+TRIM(ALIAS)+' CANNOT BE BELOW '+TRIM(LOW)+', PLEASE RE-ENTER"' ? ' CLEAR GETS' ? ' LOOP' ? ' ENDIF' IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' ? ' IF M'+TRIM(FIELD:NAME)+' > "'+TRIM(HIGH)+'"' ELSE ? ' IF M'+TRIM(FIELD:NAME)+' > '+TRIM(HIGH) ENDIF ? ' @ 23,10 SAY "'+TRIM(ALIAS)+' CANNOT BE ABOVE '+TRIM(HIGH)+', PLEASE RE-ENTER"' ? ' CLEAR GETS' ? ' LOOP' ? ' ENDIF' ENDIF ENDIF SKIP ENDDO ? 'ENDIF' ? ' SET INTE ON' ? ' @ 23,50 SAY "ALL OK? (*=QUIT)" GET MOK PICT "!"' ? ' READ ' ? ' SET INTE OFF' ? '* ----- END PROCESSING SECTION:' ? ? ' IF MOK="*"' ? ' CLEA' ? ' SET TALK ON' ? ' RETURN' ? ' ENDIF' ? ' IF MOK#"Y"' ? ' @ 23,0 SAY $(STR(0,80),1,79)' ? ' LOOP' ? ' ENDIF' ? ' CLEAR GETS' ? ' @ 23,0 SAY $(STR(0,80),1,79)' ? ' APPE BLANK' ? ' STOR mrecno+1 TO mrecno' * GENERATE REPLACE STATEMENTS ? '* ----- DATA BASE UPDATE SECTION:' GO TOP DO WHILE .NOT. EOF IF !(USED)='N'.OR.(FORMULA#' '.AND.FIELD:TYPE='N') IF !(USED)='N' .AND. FORMULA=' ' SKIP LOOP ELSE ? 'REPL '+TRIM(FIELD:NAME)+' WITH '+TRIM(FORMULA) SKIP LOOP ENDIF ENDIF DO CASE CASE FIELD:TYPE='C' IF !(ANS)='U' ? ' IF M'+TRIM(FIELD:NAME)+'#"_"' ? ' REPL '+TRIM(FIELD:NAME)+' WITH $(M'+TRIM(FIELD:NAME)+',1,@("_",M'+TRIM(FIELD:NAME)+')-1)' ? ' ELSE' ? ' REPL '+TRIM(FIELD:NAME)+' WITH M'+TRIM(FIELD:NAME) ? ' ENDIF' ELSE ? ' REPL '+TRIM(FIELD:NAME)+' WITH M'+TRIM(FIELD:NAME) ENDIF CASE FIELD:TYPE='N' ? ' REPL '+TRIM(FIELD:NAME)+' WITH M'+TRIM(FIELD:NAME) CASE FIELD:TYPE='D' ? '* DATE FIELD REVERSAL AND COMPRESSION' ? ' REPL '+TRIM(FIELD:NAME)+' WITH $(M'+TRIM(FIELD:NAME)+',7,2)+$(M'+TRIM(FIELD:NAME)+',1,2)+$(M'+TRIM(FIELD:NAME)+',4,2)' ENDCASE *IF !(INDEX)#'Y' *?? ' NOUP' *ENDIF SKIP ENDDO * GENERATE AND HANDLE DEFAULTS AND CARRY FEATURES ? '* ----- MEMORY VARIABLE UPDATE SECTION:' ? GO TOP DO WHILE .NOT. EOF IF !(USED)='N' SKIP LOOP ENDIF IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' IF !(CARRY)='N'.OR.CARRY=' ' IF FIELD:LEN>FMAXLEN ? ' *** LONG FIELD NAME, SUBSTRING USED TO FIT' ? ' STOR $(MBL80,1,'+STR(FMAXLEN,3)+') TO M'+TRIM(FIELD:NAME) ELSE ? ' STOR $(MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(FIELD:NAME) ENDIF ENDIF IF DEFAULT#' ' ? ' STOR $("'+TRIM(DEFAULT)+'"+MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(FIELD:NAME) ENDIF ELSE IF DEFAULT#' ' ? ' STOR '+STR(VAL(DEFAULT),FIELD:LEN)+' TO M'+TRIM(FIELD:NAME) ELSE ? ' STOR 0 TO M'+TRIM(FIELD:NAME) ENDIF ENDIF SKIP ENDDO ? 'ENDDO' SET ALTE OFF SET ALTE TO set inde to DELE FILE SEQ.NDX SET TALK ON CLEA CANCEL +TRIM(FIELD:NAME)+',4,2)' ENDCASE *IF !(INDEX)#'Y' *?? ' NOUP' *ENDIF SKIP ENDDO * GENERATE AND HANDLE DEFAULTS AND CARRY FEATURES ? '* ----- MEMORY VARIABLE UPDATE SECTION:' ? GO TOP DO WHILE .NOT. EOF IF !(USED)='N' SKIP LOOP ENDIF IF FIELD:TYPE='C'.OR.FIELD:TYPE='D' IF !(CARRY)='N'.OR.CARRY=' ' IF FIELD:LEN>FMAXLEN ? ' *** LONG FIELD NAME, SUBSTRING USED TO FIT' ? ' STOR $(MBL80,1,'+STR(FMAXLEN,3)+') TO M'+TRIM(FIELD:NAME) ELSE ? ' STOR $(MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(FIELD:NAME) ENDIF ENDIF IF DEFAULT#' ' ? ' STOR $("'+TRIM(DEFAULT)+'"+MBL80,1,'+STR(FIELD:LEN,3)+') TO M'+TRIM(FIELD:NAME) *********************************************************************** * Program Name.....: METALENT.CMD * Purpose..........: Data Entry For METALS * Author...........: Your Name * Copyright Notice.: Copyright (C) 1985, Your Name, All rights reserved * Date.............: 00/00/00 * dBASE II version.: 2.4x * CMD file version : 1.0 * Memory Variables.: "M"+Field names + control variables +...? * Comments/Notes...: * : *********************************************************************** * ---- ENVIRONMENT SECTION: * Reset dBASE II with no active data bases and no memory variables CLEAR SET STEP OFF ".......... Obviously." SET PRINT OFF "......... Obviously." SET ECHO OFF ".......... Obviously (unless you want to see commands)" SET TALK OFF ".......... Obviously (unless you want to see calculations)" SET ALTERNATE OFF "..... Obviously." SET ALTERNATE TO SET BELL OFF ".......... Obviously. The Bell implementation is useless" SET CARRY OFF "......... This seems like a good default state" SET COLON ON ".......... Important. Not every screen has intensity" SET CONFIRM OFF "....... Optional. You may want to default to ON." SET CONSOLE ON "........ Obviously." SET DEBUG OFF "......... Obviously." SET EJECT OFF "......... This eliminates Ejects before printout and" * requires an EJECT at the completion of a printout SET ESCAPE OFF "........ Optional. You may want to run with ESCAPE ON" SET EXACT OFF "......... Optional (though usual default is OFF)" SET FORMAT TO SCREEN ".. Obviously." SET INTENSITY OFF "..... Different screens have different ways of" * presenting intensity. It is good to start with * it off and control it. SET LINKAGE OFF "....... Obviously." SET RAW ON "............ Optional (though this is a good default position" * to prevent problems with semi-colons) SET SCREEN ON "......... Obviously." ERASE "................. Clear the screen" * Put 79 blanks in a global memory variable STORE $(STR(0,80),1,79) TO gmbl USE METALS * ---- MEMORY VARIABLE INITIALIZATION: STOR $(STR(0,81),1,80) TO MBL80 STOR $(MBL80,1, 12) TO MMATERIAL STOR $(MBL80,1, 8) TO MSPECGR STOR $(MBL80,1, 8) TO MDENSITY STOR $(MBL80,1, 8) TO MMELTPOINT STOR $(MBL80,1, 8) TO MFUSEHEAT STOR $(MBL80,1, 8) TO MSPECHEAT STOR $(MBL80,1, 8) TO MCOELINEXP STOR $(MBL80,1, 8) TO MTHERMCOND STOR $(MBL80,1, 6) TO MELECRESIS STOR $(MBL80,1, 8) TO MCOEFRESIS STOR $(MBL80,1, 8) TO MTENSTRENG STOR $(MBL80,1, 8) TO MELONGATN STOR $(MBL80,1, 8) TO MAREARED STOR $(MBL80,1, 6) TO MMODUELAST STOR $(MBL80,1, 6) TO MSHEARMOD STOR $(MBL80,1, 8) TO MBRINELL STOR $(MBL80,1, 40) TO MREMARKS * ----- SCREEN FORMAT INITIALIZATION: ERASE SET INTE ON @ 3, 1 SAY "Material Description...........:" @ 4, 1 SAY "Specific Gravity...............:" @ 5, 1 SAY "Density........................:" @ 6, 1 SAY "Melting Point..................:" @ 7, 1 SAY "Heat of fusion.................:" @ 8, 1 SAY "Specific Heat..................:" @ 9, 1 SAY "Coeficient of Linear Expansion.:" @ 10, 1 SAY "Thermal Conductivity...........:" @ 11, 1 SAY "Electrical Resistivity.........:" @ 12, 1 SAY "Coefficient of Resistivity.....:" @ 13, 1 SAY "Tensile Strength...............:" @ 14, 1 SAY "Elongation.....................:" @ 15, 1 SAY "Area Reduction.................:" @ 16, 1 SAY "Modulus of elasticity..........:" @ 17, 1 SAY "Shear Modulus..................:" @ 18, 1 SAY "Brinell Hardness...............:" @ 19, 1 SAY "Remarks........................:" SET INTE OFF GO BOTT STOR #+1 TO MRECNO STOR " " TO MOK DO WHILE T @ 23,68 SAY "REC NO:"+STR(MRECNO,4) @ 1,1 say " PHILs METALLURGICAL INFORMATION SYSTEM DATA ENTRY SCREEN" @ 2,1 say "===============================================================================" @ 22,1 say "===============================================================================" * ----- DATA INPUT SECTION: SET INTE ON @ 3, 33 GET MMATERIAL PICT "!!!!!!!!!!!!" @ 4, 33 GET MSPECGR PICT "!!!!!!!!" @ 5, 33 GET MDENSITY PICT "!!!!!!!!" @ 6, 33 GET MMELTPOINT PICT "!!!!!!!!" @ 7, 33 GET MFUSEHEAT PICT "!!!!!!!!" @ 8, 33 GET MSPECHEAT PICT "!!!!!!!!" @ 9, 33 GET MCOELINEXP PICT "!!!!!!!!" @ 10, 33 GET MTHERMCOND @ 11, 33 GET MELECRESIS PICT "!!!!!!" @ 12, 33 GET MCOEFRESIS PICT "!!!!!!!!" @ 13, 33 GET MTENSTRENG PICT "!!!!!!!!" @ 14, 33 GET MELONGATN @ 15, 33 GET MAREARED PICT "!!!!!!!!" @ 16, 33 GET MMODUELAST PICT "!!!!!!" @ 17, 33 GET MSHEARMOD PICT "!!!!!!" @ 18, 33 GET MBRINELL PICT "!!!!!!!!" @ 19, 33 GET MREMARKS READ NOUP SET INTE OFF @ 23,0 SAY $(STR(0,80),1,79) * ----- DATA VALIDATION SECTION: IF MMATERIAL # " " ENDIF SET INTE ON @ 23,50 SAY "ALL OK? (*=QUIT)" GET MOK PICT "!" READ NOUP SET INTE OFF * ----- END PROCESSING SECTION: IF MOK="*" CLEA SET TALK ON RETURN ENDIF IF MOK#"Y" @ 23,0 SAY $(STR(0,80),1,79) LOOP ENDIF CLEAR GETS @ 23,0 SAY $(STR(0,80),1,79) APPE BLANK STOR mrecno+1 TO mrecno * ----- DATA BASE UPDATE SECTION: REPL MATERIAL WITH MMATERIAL REPL SPECGR WITH MSPECGR REPL DENSITY WITH MDENSITY REPL MELTPOINT WITH MMELTPOINT REPL FUSEHEAT WITH MFUSEHEAT REPL SPECHEAT WITH MSPECHEAT REPL COELINEXP WITH MCOELINEXP REPL THERMCOND WITH MTHERMCOND REPL ELECRESIST WITH MELECRESIS REPL COEFRESIST WITH MCOEFRESIS REPL TENSTRENG WITH MTENSTRENG REPL ELONGATN WITH MELONGATN REPL AREARED WITH MAREARED REPL MODUELAST WITH MMODUELAST REPL SHEARMOD WITH MSHEARMOD REPL BRINELL WITH MBRINELL REPL REMARKS WITH MREMARKS * ----- MEMORY VARIABLE UPDATE SECTION: STOR $(MBL80,1, 12) TO MMATERIAL STOR $(MBL80,1, 8) TO MSPECGR STOR $(MBL80,1, 8) TO MDENSITY STOR $(MBL80,1, 8) TO MMELTPOINT STOR $(MBL80,1, 8) TO MFUSEHEAT STOR $(MBL80,1, 8) TO MSPECHEAT STOR $(MBL80,1, 8) TO MCOELINEXP STOR $(MBL80,1, 8) TO MTHERMCOND STOR $(MBL80,1, 6) TO MELECRESIS STOR $(MBL80,1, 8) TO MCOEFRESIS STOR $(MBL80,1, 8) TO MTENSTRENG STOR $(MBL80,1, 8) TO MELONGATN STOR $(MBL80,1, 8) TO MAREARED STOR $(MBL80,1, 6) TO MMODUELAST STOR $(MBL80,1, 6) TO MSHEARMOD STOR $(MBL80,1, 8) TO MBRINELL STOR $(MBL80,1, 40) TO MREMARKS ENDDO OND REPL ELECRESIST WITH MELECRESIS REPL COEFRESIST WITH MCOEFRESIS REPL TENSTRENG WITH MTENSTRENG REPL ELONGATN WITH MELONGATN REPL AREARED WITH MAREARED REPL MODUELAST WITH MMODUELAST REPL SHEARMOD WITH MSHEARMOD REPL BRINELL WITH MBRINELL REPL REMARKS WITH MREMARKS * ----- MEMORY VARIABLE UPDATE SECTION: STOR $(MBL80,1, 12) TOMATERIALC lSPECGRClDENSITYClMELTPOINTClFUSEHEATClSPECHEATClCOELINEXPCmTHERMCONDC mELECRESISTCmCOEFRESISTCmTENSTRENGC#mELONGATNC+mAREAREDC3mMODUELASTC;mSHEARMODCAmBRINELLCGmREMARKSC(Om ALUMINUM 2.7 168.56 1217.7 138.24 .2089 .0123 1475 2.828 .0039 9 60 10 3.87 15 PURE METAL ALUMINUM 2.7 168.56 1217.7 138.24 .2250 .01285 1475 2.828 .0039 19 TO 44.5 TO 13 10 40 - 150CAST ALLOYS ALUMINUM 2.7 168.56 1217.7 138.24 .2739 .0175 1560 8.0 .005 13 TO 683 TO 35 10 3.87 23 - 116WROUGHT ALLOYS ANTIMONY 6.62 413.2 1166 70.2 .0489 .0587 128 41.7 .0036 1.5 11.3 2.86 BRITTLE BLUISH WHITE CRYSTALINE ARSENIC 5.73 357.7 1562 .0822 .03105 35 .0042 147 GRAY ARSENIC IRON 3.4 7.603 800 600 23 9 5.054 4.567 2.2222 6.789 1.009 .9876554.333 .888 7.888 TEST ENTRY BY MARK FJKDS JDSKF JKDSFJDKSJ JKDSFJKDFJDKSJFKDLSAFJDSFJDKS;FJKD;JFKDL;FJKDFKFJDKFJDKFJDKFJDKFJDKFJDJDFJDJFKDJFKDSLAF;JDKKDJF IRON 9.3 3.2 3.3 4.4 5.5 6.6 3.4.4.4 3,3,3,3 DKEJ 3KJ4 3K4J3 4J 3J45 J3 THIS IS A TEST ENTRY AS YOU CAN PLAINLY  ALUMINUM 2.7 168.56 1217.7 138.24 .2739 .0175 1560 8.0 .005 13 TO 683 TO 35 10 3.87 23 - 116WROUGHT ALLOYS AFIELD:NAMEC lALIASClFIELD:TYPEClFIELD:LENNlFIELD:DECNlSEQUENCENmROWNmACOLNmFCOLNmCARRYC mDEFAULTC2 mPICTUREC2?mREQDCqmFILLCsmHIGHC umLOWC mFORMULAC2mINDEXCmUSEDCm MATERIAL Material Description C 12 0 1 3 1 31 !!!!!!!!!!!! SPECGR Specific Gravity C 8 0 2 4 1 31 !!!!!!!! DENSITY Density  C 8 0 3 5 1 31 !!!!!!!! MELTPOINT Melting Point C 8 0 4 6 1 31 !!!!!!!! FUSEHEAT Heat of fusion C 8 0 5 7 1 31 !!!!!!!! SPECHEAT Specific Heat C 8 0 6 8 1 31 !!!!!!!! COELINEXP Coeficient of Linear ExpansionC 8 0 7 9 1 31  !!!!!!!! THERMCOND Thermal Conductivity C 8 0 810 1 31 ELECRESISTElectrical Resistivity C 6 0 911 1 31 !!!!!! COEFRESISTCoefficient of Resistivity C 8 01012 1 31 !!!!!!!! TENSTRENG Tensile Strength C 8 01113 1 31 !!!!!!!!   ELONGATN Elongation C 8 01214 1 31 AREARED Area Reduction C 8 01315 1 31 !!!!!!!! MODUELAST Modulus of elasticity C 6 01416 1 31 !!!!!! SHEARMOD Shear Modulus C 6 01517 1 31 !!!!!!  BRINELL Brinell Hardness C 8 01618 1 31 !!!!!!!! REMARKS Remarks C 40 01719 1 31  MODUELAST Modulus of elasticity C 6 01416 1 31 !!!!!! SHEARMOD Shear Modulus C 6 01517 1 31 !!!!!! yNAMEClADDRESSClADDRESS2C mREMARKSC+m MARK SCARAMELLA 12123 FOURTH ST FRESNO CA 95126 JOE SMITH 12123 FOURTH ST SAN JOSE CA JIM JOHNSON 1 SAN JOSE, CA  c/o ESD Corporation * 600 Meridian Ave. * San Jose, CA 95126 * * FIELD:NAMEC lALIASClFIELD:TYPEClFIELD:LENNlFIELD:DECNlSEQUENCENmROWNmACOLNmFCOLNmCARRYC mDEFAULTC2 mPICTUREC2?mREQDCqmFILLCsmHIGHC umLOWC mFORMULAC2mINDEXCmUSEDCm NAME NAME OF PERSON C 30 0 1 3 1 15Y !!!!!!!!!!!!!!!!!!!!!!!!!!!!! ADDRESS FIRST ADDRESS C 30 0 2 4 1 15 12123 FOURTH ST !!!!!!!!!!!!!!!!!!!!!!!!!!!!! Y ADDRESS2 CITY/STATE/ZIP C 30 0 3 5 1 15 / / . REMARKS C 30 0 4 0 1 0 N ."$dbfile stor !($(dbfile,1,@(".",dbfile))+"dbs") TO dbsc NAME NAME OF PERSON C 30 0 1 3 1 15Y !!!!!!!!!!!!!!!!!!!!!!!!!!!!! ADDRESS FIRST ADDRESS C 30 0 2 4 1 15 12123 FOURTH ST !!!!!!!!!!!!!!!!!!!!!!!!!!!!! Y ADDRESS2 CITY/STATE/ZIP! *********************************************************************** * Program Name.....: TESTENT.CMD * Purpose..........: Data Entry For TEST * Author...........: Your Name * Copyright Notice.: Copyright (C) 1985, Your Name, All rights reserved * Date.............: 00/00/00 * dBASE II version.: 2.4x * CMD file version : 1.0 * Memory Variables.: "M"+Field names + control variables +...? * Comments/Notes...: * : *********************************************************************** * ---- ENVIRONMENT SECTION: * Reset dBASE II with no active data bases and no memory variables CLEAR SET STEP OFF ".......... Obviously." SET PRINT OFF "......... Obviously." SET ECHO OFF ".......... Obviously (unless you want to see commands)" SET TALK OFF ".......... Obviously (unless you want to see calculations)" SET ALTERNATE OFF "..... Obviously." SET ALTERNATE TO SET BELL OFF ".......... Obviously. The Bell implementation is useless" SET CARRY OFF "......... This seems like a good default state" SET COLON ON ".......... Important. Not every screen has intensity" SET CONFIRM OFF "....... Optional. You may want to default to ON." SET CONSOLE ON "........ Obviously." SET DEBUG OFF "......... Obviously." * included in a command with a scope (v. 2.4 only) SET EJECT OFF "......... This eliminates Ejects before printout and" * requires an EJECT at the completion of a printout SET ESCAPE OFF "........ Optional. You may want to run with ESCAPE ON" SET EXACT OFF "......... Optional (though usual default is OFF)" SET FORMAT TO SCREEN ".. Obviously." SET INTENSITY OFF "..... Different screens have different ways of" * presenting intensity. It is good to start with * it off and control it. SET LINKAGE OFF "....... Obviously." SET RAW ON "............ Optional (though this is a good default position" * to prevent problems with semi-colons) SET SCREEN ON "......... Obviously." ERASE "................. Clear the screen" * Put 79 blanks in a global memory variable STORE $(STR(0,80),1,79) TO gmbl USE TEST STOR "_____________________________________________________________" TO MBL80 STOR $(MBL80,1, 30) TO MNAME STOR $("12123 FOURTH ST"+MBL80,1, 30) TO MADDRESS STOR $(MBL80,1, 30) TO MADDRESS2 * ----- SCREEN FORMAT INITIALIZATION: ERASE SET INTE ON @ 3, 1 SAY "NAME OF PERSON.:" @ 4, 1 SAY "FIRST ADDRESS..:" @ 5, 1 SAY "CITY/STATE/ZIP.:" SET INTE OFF GO BOTT STOR #+1 TO MRECNO STOR " " TO MOK DO WHILE T @ 23,68 SAY "REC NO:"+STR(MRECNO,4) @ 1,1 say " TEST" @ 2,1 say "===============================================================================" @ 22,1 say "===============================================================================" * ----- DATA INPUT SECTION: SET INTE ON @ 3, 17 GET MNAME PICT "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!" @ 4, 17 GET MADDRESS PICT "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!" @ 5, 17 GET MADDRESS2 READ SET INTE OFF @ 23,0 SAY $(STR(0,80),1,79) * ----- DATA VALIDATION SECTION: IF MNAME # " " IF MADDRESS = " " @ 23,10 SAY CHR(7) @ 23,10 SAY "FIRST ADDRESS IS A REQUIRED ENTRY, PLEASE RE-ENTER" CLEAR GETS LOOP ENDIF ENDIF SET INTE ON @ 23,50 SAY "ALL OK? (*=QUIT)" GET MOK PICT "!" READ SET INTE OFF * ----- END PROCESSING SECTION: IF MOK="*" CLEA SET TALK ON RETURN ENDIF IF MOK#"Y" @ 23,0 SAY $(STR(0,80),1,79) LOOP ENDIF CLEAR GETS @ 23,0 SAY $(STR(0,80),1,79) APPE BLANK STOR mrecno+1 TO mrecno * ----- DATA BASE UPDATE SECTION: IF MNAME#"_" REPL NAME WITH $(MNAME,1,@("_",MNAME)-1) ELSE REPL NAME WITH MNAME ENDIF IF MADDRESS#"_" REPL ADDRESS WITH $(MADDRESS,1,@("_",MADDRESS)-1) ELSE REPL ADDRESS WITH MADDRESS ENDIF IF MADDRESS2#"_" REPL ADDRESS2 WITH $(MADDRESS2,1,@("_",MADDRESS2)-1) ELSE REPL ADDRESS2 WITH MADDRESS2 ENDIF * ----- MEMORY VARIABLE UPDATE SECTION: STOR $(MBL80,1, 30) TO MADDRESS STOR $("12123 FOURTH ST"+MBL80,1, 30) TO MADDRESS STOR $(MBL80,1, 30) TO MADDRESS2 ENDDO GH)+'"' ELSE ? ' IF M'+TRIM(FIELD:NAME)+' > '+TRIM(HIGH) ENDIF ? ' @ 23,10 SAY "'+TRIM(ALIAS)+' CANNOT BE ABOVE '+TRIM( MOK PICT "!" READ SET INTE OFF * ----- END PROCESSING SECTION: IF MOK="*" CLEA SET TALK ON RETURN ENDIF IF MOK#"Y" @ 23,0 SAY $(STR(0,80),1,79) LOOP ENDIF CLEAR GETS @ 23,0 SAY $(STR(0,80),1,79) APPE BLANK STOR mrecno+1 TO mrecno * ----- DATA BASE UPDATE SECTION: IF MNAME#"_" REPL NAME WITH $(MNAME,1,@("_",MNAME)-1) ELSE REPL NAME WITH MNAME ENDIF IF MADDRESS#"_" REPL ADDRESS WITH $(MADDRESS,1,@"iFIELD:NAMEC ALIASCFIELD:TYPECFIELD:LENNFIELD:DECNSEQUENCENROWNACOLNFCOLNCARRYCDEFAULTC2PICTUREC2REQDCFILLCHIGHC LOWC FORMULAC2INDEXCUSEDC ot for resale without the explicit permission * of the author. Modifications for personal * use are authorized and encouraged. * Please notify author of any improvements or * fixes implemented or requested at: * * Mark C. Scaramella * c/o ESD Corporation * 600 Meridian Ave. * San Jose, CA 95126 * *  This is the release date of the disk. !K"K$K%K&K'K(K)K+K,K-K.K/K2K3K4K5K6K7K8K9K:K;KK?K@KAKBKCKDKEKFKGKHKIKJKKKLKMKNKOKPKQKRKSKTKUKVKWKXKYKZK[K\K]K^K_K`KaKbKcKdKeKfKgKhKiKjKkKlKmKnKoKpKqKrKsKtKuKvKwKxKyKzK{K|K}K~KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKLPRINTLBL.CMD B6 6A 128 1 PRINTOFF.CMD 38 E0 128 1 PRINTREP.CMD EC 4A 128 1 REP .FMT A8 5D 1408 11 SEARCH .CMD 37 96 384 3 SELECTMN.FMT 80 9A 1536 12 UP1LBL .CMD A7 AF 384 3 UP1SEL .CMD 7C EE 1152 9 UP2LBL .CMD FA 16 1280 10 UP2SEL .CMD D2 AA 2176 17 UP3LBL .CMD 1E B9 1664 13 UP3SEL .CMD EC D8 2688 21 UPDATE  Fog Library Disk FOG-CPM.078 Copyright (1986) by Fog International Computer Users Group to the extent not copyrighted by the original author for the exclusive use and enjoyment of its members. Any reproduction or distribution for profit or personal gain is strictly forbidden. For information, contact FOG, P. O. Box 3474, Daly City, CA. 94015-0474. as part of the description of a file indicates that the program is distributed on a "try first, pay if you like it" basis. If you find the program(s) meet your need, please refer to the author's documentation for information on becoming a registered user. Only by registering and paying for the programs you like and use will the authors of such programs continue development. Often, more complete documentation, additional modules, and new releases are available only to registered users. dBASE II programs. Filename Description -06-00 .86 This is the release date of the disk. -CPM078 .DOC This is the description of the disk contents. LOADER .CMD 3079 1K [ApexMail 1 of 31] dBASE II mailing list system. Prints labels (one, two, or three up), postcards, and lists. Fully menu-driven. MAIL .DOC A662 2K [ApexMail 2 of 31] MAILCOMP.NDX E422 3K [ApexMail 3 of 31] MAILREP .CMD C0B8 2K [ApexMail 4 of 31] MAILZIP .NDX 6074 2K [ApexMail 5 of 31] MAINMENU.FMT 5368 2K [ApexMail 6 of 31] MAKEMEM .CMD 339E 1K [ApexMail 7 of 31] POSTCARD.FMT 28B6 2K [ApexMail 8 of 31] PRELUDE .CMD C8CC 3K [ApexMail 9 of 31] PRINTLBL.CMD B66A 1K [ApexMail 10 of 31] PRINTOFF.CMD 38E0 1K [ApexMail 11 of 31] PRINTREP.CMD EC4A 1K [ApexMail 12 of 31] REP .FMT A85D 2K [ApexMail 13 of 31] SEARCH .CMD 3796 1K [ApexMail 14 of 31] SELECTMN.FMT 809A 2K [ApexMail 15 of 31] UP1LBL .CMD A7AF 1K [ApexMail 16 of 31] UP1SEL .CMD 7CEE 2K [ApexMail 17 of 31] UP2LBL .CMD FA16 2K [ApexMail 18 of 31] UP2SEL .CMD D2AA 3K [ApexMail 19 of 31] UP3LBL .CMD 1EB9 2K [ApexMail 20 of 31] UP3SEL .CMD ECD8 3K [ApexMail 21 of 31] UPDATE .CMD 6DF8 1K [ApexMail 22 of 31] UPDATEMN.FMT DFC0 2K [ApexMail 23 of 31] ADD .MEM 6F0E 3K [ApexMail 24 of 31] ALPH .FRM 3C4D 1K [ApexMail 25 of 31] APEXMAIL.DBF 56CC 2K [ApexMail 26 of 31] CARDS .CMD FEA0 2K [ApexMail 27 of 31] DUMP .FRM B544 1K [ApexMail 28 of 31] HELLO .CMD A11F 1K [ApexMail 29 of 31] LABELMEN.FMT 980F 2K [ApexMail 30 of 31] LABELS .CMD 735B 1K [ApexMail 31 of 31] DSCREEN .CMD 5170 19K [dSCREEN 1 of 10] Screen generator program which helps you# produce dBASE (2.4x) code for data entry screens that include error checking. Includes samples. DSCREEN .DOC 429E 37K [dSCREEN 2 of 10] DSCREEN .23B 022A 19K [dSCREEN 3 of 10] METALENT.CMD 1C3C 7K [dSCREEN 4 of 10] METALS .DBF 67B0 2K [dSCREEN 5 of 10] METALS .DBS 984F 5K [dSCREEN 6 of 10] TEST .DBF 502B 1K [dSCREEN 7 of 10] TEST .DBS D77A 2K [dSCREEN 8 of 10] TESTENT .CMD 50EA 5K [dSCREEN 9 of 10] XSCREEN .DBF 1447 1K [dSCREEN 10 of 10] f 31] UP2LBL .CMD FA16 2K [ApexMail 18 of 31] UP2SEL .CMD D2AA 3K [ApexMail 19 of 31] UP3LBL .CMD 1EB9 2K [ApexMail 20 of 31] UP3SEL .CMD ECD8 3K [ApexMail 21 of 31] UPDATE .CMD 6DF8 1K [ApexMail 22 of 31] UPDATEMN.FMT DFC0 2K [ApexMail 23 of 31] ADD .MEM 6F0E 3K [ApexMail 24 of $%&'