# ######################################################### # appgen.rul rule file for standard appgen modules # # Based upon Appgen 5.0 demo data # ######################################################### # This rule file is provided "AS IS", without warranty. # # Under no circumstances will the publisher be liable # # for consequential damages resulting from the use or # # inability to use the contents. # ######################################################### # # 11/07/02 # Adjust the following constants to correct files and info const COMP_NAME="Synergetic Data Systems Inc" const COMP_ADDR1="2195 Talon Drive" const COMP_ADDR2="Latrobe CA 95682" const COMP_PHONES="530/672-9970 Fax: 672-9975" const COMP_PCLLOGO="sdsilogo.pcl" const COMP_PDFLOGO="sdsilogo.pdf" const SIGNATURE="" const SCISSORSLOGO="scissors.pcl" const AP_MICR_ACCOUNTNO=":123456789:9999-1234<34>" const PR_MICR_ACCOUNTNO=":987654321:1111-9876<34>" const AP_NO_STUBS=2 # 1=vendor stub, 2=vendor stub and payor stub const PR_NO_STUBS=2 # 1=employee stub, 2=employee stub and employer stub # # Changing columns to proportional fonts make the document look VERY professional # It also slows down the printing process # To increase speed, look for sections starting with ##### and remark out lines as desired # ############################ # Module: Accounts Payable # ############################ [AP Detailed Aging Report] detect 0,2,"Detailed Aged Payables" const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS rows 66 pcopies 1 prepage { compname$=trim(get(45,1,40)) title$=trim(get(45,2,40)) pgmname$=trim(get(1,1,10)) pageno$=trim(get(124,1,13)) time$=trim(get(113,2,8)) rptdate$=trim(get(122,2,11)) } # header const HFONT=univers,9,bold cerase 1,1,MAXCOLS,2 cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT const HFONT=cgtimes,10 cmove 1,4,60,5,2,4 cfont 2,4,20,4,HFONT cfont 23,4,44,5,HFONT,right,cols=23 cfont 46,4,60,5,HFONT,bold cfont 67,4,78,5,HFONT,right,cols=14 cfont 80,4,92,5,HFONT,bold const HFONT=univers,9 cmove 1,8,130,9,2,8 cfont 2,8,MAXCOLS,9,HFONT # body const HFONT=cgtimes,9,italic const DFONT=cgtimes,10 erase "Vendor Code & Name",0,0,50,2 box "Vendor Code & Name",-1,1,51,2,1,10 font "Vendor Code & Name",0,2,50,1,DFONT erase "Voucher Reference",0,1,MAXCOLS,1 box "Voucher Reference",0,1,MAXCOLS,1 font "Voucher Reference",0,0,17,1,HFONT font "Vouchr",0,0,6,1,HFONT font "Vouchr",7,0,2,1,HFONT font "PO Number",0,0,9,1,HFONT font "Invoice No",0,0,10,1,HFONT font "Inv Date",0,0,8,1,HFONT font "Due Date",0,0,8,1,HFONT font "Dsc Date",0,0,8,1,HFONT font "Inv Amount",0,0,10,1,HFONT font "Applied",0,0,7,1,HFONT font "Disc.",0,0,5,1,HFONT font "Inv Net",0,0,7,1,HFONT font "Age@130",0,0,3,1,HFONT # totals erase "Totals for Vendor",0,-1,75,1 font "Totals for Vendor",0,0,31,1,HFONT,bold bold "Totals for Vendor",0,0,77,1 box "Totals for Vendor",33,-1,40,1,5 erase "Current",-2,1,55,1 font "Current",0,0,7,1,HFONT box "Current",-2,1,55,1 font "Current",-2,2,11,1,DFONT,bold font "31-60 Days",0,0,10,1,HFONT font "31-60 Days",0,2,11,1,DFONT,bold font "61-90 Days",0,0,10,1,HFONT font "61-90 Days",0,2,11,1,DFONT,bold font "Over 90",0,0,7,1,HFONT font "Over 90",-2,2,11,1,DFONT,bold erase "Grand Totals",0,-1,70,1 font "Grand Totals",0,0,16,1,HFONT,bold box "Grand Totals",-1,-1,72,2,1,10 font "Grand Totals",27,0,9,1,DFONT,bold font "Grand Totals",38,0,9,1,DFONT,bold font "Grand Totals",49,0,6,1,DFONT,bold font "Grand Totals",58,0,9,1,DFONT,bold [AP Summary Aging Report] detect 0,2,"Summary Aged Payables" const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS rows 66 pcopies 1 prepage { compname$=trim(get(45,1,40)) title$=trim(get(45,2,40)) pgmname$=trim(get(1,1,10)) pageno$=trim(get(124,1,13)) time$=trim(get(113,2,8)) rptdate$=trim(get(122,2,11)) } # header const HFONT=univers,9,bold cerase 1,1,MAXCOLS,2 cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT const HFONT=cgtimes,10 cmove 1,4,60,5,2,4 cfont 2,4,20,4,HFONT cfont 23,4,44,5,HFONT,right,cols=23 cfont 46,4,60,5,HFONT,bold cfont 67,4,78,5,HFONT,right,cols=14 cfont 80,4,92,5,HFONT,bold # body const HFONT=cgtimes,10,italic const DFONT=cgtimes,9 cbox 0.1,7,MAXCOLS,9,1,10 cerase 1,8,MAXCOLS,9 text 1,8,"Vendor Name",HFONT text 38,8,"Terms",HFONT text 55,8,"Current",HFONT,right,cols=13 text 71,8,"31-60 Days",HFONT,right,cols=13 text 87,8,"61-90 Days",HFONT,right,cols=13 text 103,8,"Over 90",HFONT,right,cols=13 text 119,8,"Open Amount",HFONT,right,cols=13 cfont 1,10,35,66,DFONT cfont 38,10,52,66,DFONT ##### To increase speed, make the following lines remarks (#) cfont 55,10,67,66,DFONT,right,cols=12,black cfont 71,10,83,66,DFONT,right,cols=12 cfont 87,10,99,66,DFONT,right,cols=12,black cfont 103,10,115,66,DFONT,right,cols=12 cfont 119,10,131,66,DFONT,right,bold,cols=12,black # totals erase "Aged Grand Totals",22,-1,78,1 font "Aged Grand Totals",0,0,20,1,HFONT,bold box "Aged Grand Totals",-2,-1,103,2,5,10 bold "Aged Grand Totals",0,0,103,1 [AP Checks] # Using plain paper detect 19,1,"~../../.." detect 53,25,"~../../.." const MAXCOLS=83 const MAXRCOLS=82 cols MAXCOLS rows 66 pcopies 2 prepage { # load up check data for later placement chkno$=trim(get(1,22,81));x$=set(1,22,81,"") chkdate$=trim(get(1,25,60)) chkamt$=trim(get(61,25,21));x$=set(1,25,81,"") chkamt_words$=trim(get(1,27,81));x$=set(1,27,81,"") name$=trim(get(1,32,81));x$=set(1,32,81,"") addr1$=trim(get(1,33,81));x$=set(1,33,81,"") addr2$=trim(get(1,34,81));x$=set(1,34,81,"") addr3$=trim(get(1,35,81));x$=set(1,35,81,"") } precopy { if copy=1 and copy<>AP_NO_STUBS then skip=1 if copy=2 and copy<>AP_NO_STUBS then skip=1 } const SHFONT=cgtimes,11,shade 0 const DFONT=cgtimes,12,bold const HFONT=cgtimes,12,italic # Top stub - Payor's cmove 1,1,81,17,2,3 if copy 1 cerase 2,3,82,19 endif if copy 2 cbox 1,1,MAXCOLS,22,4 cbox 1,1,MAXCOLS,2,1,100 cbox 1,1,MAXCOLS,19 cbox 8,1,8,19 cbox 19,1,19,19 cbox 28,1,28,19 cbox 41,1,41,19 cbox 53,1,53,19 cbox 66,1,66,19 text 1.5,1.5,"Voucher #",SHFONT text 9,1.5,"Invoice #",SHFONT text 20,1.5,"Invoice Date",SHFONT,center,cols=8 text 29,1.5,"Invoice Amount",SHFONT,right,cols=11 text 42,1.5,"Amount Paid",SHFONT,right,cols=11 text 54,1.5,"Discount Taken",SHFONT,right,cols=11 text 67,1.5,"Check Amount",SHFONT,right,cols=16 cfont 67,3,82,19,DFONT,right,cols=16 # top stub bottom text 2,20,"Vendor:",HFONT text 10,20,{name$},DFONT text 2,21,"Date:",HFONT text 10,21,{chkdate$},DFONT text 42,20,"Check #",HFONT text 50,20,{chkno$},DFONT text 42,21,"Amount:",HFONT text 50,21,{chkamt$},DFONT text 74,21,"Payor Copy",DFONT endif # Middle stub - Vendor's cbox 1,22.5,MAXCOLS,22.5 cbox 1,23,MAXCOLS,44,4 cbox 1,23,MAXCOLS,24,1,100 cbox 1,23,MAXCOLS,41 cbox 8,23,8,41 cbox 19,23,19,41 cbox 28,23,28,41 cbox 41,23,41,41 cbox 53,23,53,41 cbox 66,23,66,41 cmove 2,3,82,18,2,25,1 text 1.5,23.5,"Voucher #",SHFONT text 9,23.5,"Invoice #",SHFONT text 20,23.5,"Invoice Date",SHFONT,center,cols=8 text 29,23.5,"Invoice Amount",SHFONT,right,cols=11 text 42,23.5,"Amount Paid",SHFONT,right,cols=11 text 54,23.5,"Discount Taken",SHFONT,right,cols=11 text 67,23.5,"Check Amount",SHFONT,right,cols=16 cfont 68,24,82,41,DFONT,right,cols=16 # bottom part of middle stub text 2,42,"Payor:",HFONT text 8,42,"COMP_NAME",DFONT text 2,43,"Date:",HFONT text 8,43,{chkdate$},DFONT text 42,42,"Check #",HFONT text 49,42,{chkno$},DFONT text 42,43,"Amount:",HFONT text 49,43,{chkamt$},DFONT text 73,43,"Vendor Copy",DFONT # Check cbox 1,44.5,MAXCOLS,44.5 cbox 1,45,MAXCOLS,65,4,10 if driver pdf image 1,45.1,12,6,"COMP_PDFLOGO" endif if driver laser image 1,45.1,12,6,"COMP_PCLLOGO" endif text 15,47,"COMP_NAME",univers,15,bold text 15,48,"COMP_ADDR1",univers,12 text 15,49,"COMP_ADDR2",univers,12 text 64,47,"Check Number",HFONT text 76,47,{chkno$},cgtimes,18,bold cbox 55,49,65,50,1,100 cbox 55,50,65,51.5 text 56,49.5,"Date",SHFONT,shade 0,center,cols=9 text 56,51,{chkdate$},DFONT,center,cols=9 cbox 69,49,82,50,1,100 cbox 69,50,82,51.5 text 70,49.5,"Amount",SHFONT,shade 0,right,cols=12 text 70,51,{chkamt$},DFONT,right,cols=12 text 2,53.5,{chkamt_words$},DFONT,italic text 2,58,"Pay to the Order of",HFONT text 11,59,{name$},DFONT text 11,60,{addr1$},DFONT text 11,61,{addr2$},DFONT text 11,62,{addr3$},DFONT dump 50,63,SIGNATURE box 50,63.5,30,1,3 text 50,64.2,"Authorized Signature",HFONT,center,cols=30 micr 10,65,AP_MICR_ACCOUNTNO,{chkno$} [AP Generic] # This rule set will set columns & rows and enhance the heading for other AP reports detect 1,1,"AP" detect 0,1,"Page" cols 132 rows 66 # copy 1 is generic 80 column, copy 2 is generic 132 column pcopies 2 prepage { maxlen=80 for i=1 to 66 if len(text$[i])>maxlen then maxlen=len(text$[i]) next i pgmname$=trim(get(1,1,10)) x=pos("Page"=text$[1]) compname$=trim(get(11,1,x-1-10)) pageno$=trim(get(x,1,11)) a=mask("","..:..:..") a=mask(text$[2]) title$=trim(get(1,2,a-1)) time$=trim(get(a,2,8)) rptdate$=trim(get(a+8,2,11)) } precopy { if maxlen>132 then skip=1 if copy=1 and maxlen>80 then skip=1 if copy=2 and maxlen=80 then skip=1 } # header const HFONT=univers,9,bold cerase 1,1,132,2 if copy 1 const MAXCOLS=80 const MAXRCOLS=79 cols MAXCOLS box .1,.1,80.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif if copy 2 const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif ############################### # Module: Accounts Receivable # ############################### [AR Detailed Aging Report] detect 0,2,"Detailed Aged Receivables" const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS rows 66 pcopies 1 prepage { compname$=trim(get(50,1,40)) title$=trim(get(50,2,40)) pgmname$=trim(get(1,1,10)) pageno$=trim(get(120,1,13)) time$=trim(get(113,2,8)) rptdate$=trim(get(122,2,11)) } # header const HFONT=univers,9,bold cerase 1,1,MAXCOLS,2 cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT const HFONT=cgtimes,10 cerase 0,8,MAXCOLS,8 cmove 1,4,54,7,2,4 cfont 2,4,20,4,HFONT cfont 23,4,46,8,HFONT,right,cols=23 cfont 48,4,55,8,HFONT,bold cfont 68,4,83,8,HFONT,right,cols=14 cfont 84,4,92,8,HFONT,bold cfont 97,7,MAXCOLS,8,HFONT,right,cols=35 # body header const HFONT=cgtimes,10,italic const DFONT=cgtimes,10 erase "Customer Code C",-1,-1,MAXCOLS,1 erase "Customer Code C",-1,1,MAXCOLS,1 box "Customer Code C",-1,-1,MAXCOLS,2,1,10 font "Customer Code C",0,0,45,1,HFONT font "Deposit Bal",0,0,11,1,HFONT font "SalesRep",0,0,8,1,HFONT font "Telephone",0,0,9,1,HFONT bold "Customer Code C",0,2,MAXCOLS,1 font "~ [0-9]@1,12,5",3,0,5,1,DFONT font "~ [0-9]@1,12,5",10,0,75,1,DFONT font "~...-...-....",0,0,12,1,DFONT font "~...-...-....",-9,0,7,1,DFONT # body detail const HFONT=cgtimes,8 erase "Doc Number",0,1,MAXCOLS,1 box "Doc Number",0,1,MAXCOLS,1 font "Doc Number",0,0,10,1,HFONT font " T ",0,0,3,1,HFONT,center,cols=3 font "Doc Date",0,0,8,1,HFONT,center,cols=8 font "Reference",0,0,9,1,HFONT font "Original Amt",0,0,12,1,HFONT font "Open Amount",0,0,12,1,HFONT font "Current",0,0,12,1,HFONT font "31-60",0,0,12,1,HFONT font "61-90",0,0,12,1,HFONT font "OVER 90",0,0,12,1,HFONT font "~../../..@1,12",-13,0,8,1,DFONT font "~../../..@1,12",-2,0,1,1,DFONT,center,cols=3 font "~../../..@1,12",0,0,8,1,DFONT,center,cols=8 ##### You can rem (#) out the following to increase speed font "~\.[0-9][0-9]@49,11,62",-9,0,13,1,DFONT,right,cols=12,black font "~\.[0-9][0-9]@64,11,76",-9,0,13,1,DFONT,right,cols=12 font "~\.[0-9][0-9]@78,11,90",-9,0,13,1,DFONT,right,cols=12,black font "~\.[0-9][0-9]@92,11,104",-9,0,13,1,DFONT,right,cols=12 font "~\.[0-9][0-9]@106,11,118",-9,0,13,1,DFONT,right,cols=12,black font "~\.[0-9][0-9]@120,11,132",-9,0,13,1,DFONT,right,cols=12 # totals box "Totals for Cust",35,-1,70,1 bold "Totals for Cust",0,0,105,1 erase "Totals for Cust",0,-1,105,1 font "Totals for Cust",0,0,30,1,DFONT,bold erase "Grand Totals",0,-1,106,1 box "Grand Totals",-2,-1,108,2,5,10 font "Grand Totals",0,0,15,1,DFONT,bold bold "Grand Totals",0,0,106,1 [AR Summary Aging Report] detect 0,2,"Summary Aged Receivables" const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS rows 66 pcopies 1 prepage { compname$=trim(get(50,1,40)) title$=trim(get(50,2,40)) pgmname$=trim(get(1,1,10)) pageno$=trim(get(120,1,13)) time$=trim(get(113,2,8)) rptdate$=trim(get(122,2,11)) } # header const HFONT=univers,9,bold cerase 1,1,MAXCOLS,2 cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT const HFONT=cgtimes,10 cerase 0,8,MAXCOLS,8 cmove 1,4,54,7,2,4 cfont 2,4,20,4,HFONT cfont 23,4,46,7,HFONT,right,cols=23 cfont 48,4,55,7,HFONT,bold cfont 68,4,83,7,HFONT,right,cols=14 cfont 84,4,92,7,HFONT,bold cfont 97,7,MAXCOLS,7,HFONT,right,cols=35 # body const HFONT=cgtimes,10,italic const DFONT=cgtimes,9 cbox 0.1,8,MAXCOLS,10,1,10 cerase 1,9,MAXCOLS,10 text 1,9,"Customer",HFONT text 37,9,"Telephone",HFONT,center,cols=12 text 50,9,"SR",HFONT,center,cols=2 text 53,9,"Current",HFONT,right,cols=12 text 67,9,"31-60",HFONT,right,cols=12 text 81,9,"61-90",HFONT,right,cols=12 text 95,9,"Over 90",HFONT,right,cols=12 text 109,9,"Open Amount",HFONT,right,cols=12 text 123,9,"Crd Limit",HFONT,right,cols=9 shade 1,11,MAXCOLS,3,1,3,10 cfont 1,11,35,66,DFONT font "~...-...-....",0,0,12,1,DFONT,center,cols=12 cfont 50,11,51,66,DFONT,center,cols=2 bold 109,11,121,66 ##### To increase speed, make the following lines remarks (#) cfont 53,11,65,66,DFONT,right,cols=12,black cfont 67,11,79,66,DFONT,right,cols=12 cfont 81,11,93,66,DFONT,right,cols=12,black cfont 95,11,107,66,DFONT,right,cols=12 cfont 109,11,121,66,DFONT,bold,right,cols=12,black cfont 123,11,132,66,DFONT,right,cols=9 # totals erase "Grand Totals",0,-1,85,1 font "Grand Totals",0,0,15,1,HFONT,bold box "Grand Totals",-2,-1,87,2,5,10 bold "Grand Totals",0,0,85,1 [AR Statement] detect 64,3,"~../../.." detect 0,57,"Current" detect 0,57,"Over" const MAXCOLS=80 const MAXRCOLS=79 cols MAXCOLS page 66 rows 66 pcopies 2 prepage{ # Appgen inserts a blank line on some forms after first page, so shift up one line as needed trash$=trim(text$[3]) if trash$="" then \ for i=2 to 66; \ text$[i-1]=text$[i]; \ text$[i]=""; \ next i # get company address name$=trim(get(10,7,40)) add1$=trim(get(10,8,40)) add2$=trim(get(10,9,40)) add3$=trim(get(10,10,40)) dt$=trim(get(64,3,8)) custno$=trim(get(64,6,15)) } # Top section const SHADE=10 text 1,2.25,"STATEMENT",univers,18,bold,right,cols=MAXRCOLS if driver pdf image 1,1,12,6,"COMP_PDFLOGO" endif if driver laser image 1,1,12,6,"COMP_PCLLOGO" endif text 1,2.25,"COMP_NAME",univers,15,bold,center,cols=MAXCOLS text 1,3.35,"COMP_ADDR1",univers,12,center,cols=MAXCOLS text 1,4.35,"COMP_ADDR2",univers,12,center,cols=MAXCOLS text 1,5.35,"COMP_PHONES",univers,12,center,cols=MAXCOLS if copy 1 text 1,5,"Customer Copy",univers,12,bold,right,cols=MAXRCOLS endif if copy 2 text 1,5,"Accounting Copy",univers,12,bold,right,cols=MAXRCOLS endif erase 64,3,8 cbox 60,6.25,MAXCOLS,11.25 cbox 60,6.25,MAXCOLS,7.5,1,SHADE text 60,7,"Date",univers,9,center,cols=20 text 60,8.25,{dt$},univers,9,bold,center,cols=20 erase 64,6,15 cbox 60,8.75,MAXCOLS,10,1,SHADE text 60,9.5,"Account Number",univers,9,center,cols=20 text 60,10.75,{custno$},univers,9,bold,center,cols=20 erase 10,7,40,4 text 10,11.25,{name$},14,bold,univers text 10,12.35,{add1$},12,univers text 10,13.35,{add2$},12,univers text 10,14.35,{add3$},12,univers box 0,17,MAXCOLS,1 text 5,16.5,"Please detach and return this portion with your payment.",univers,7 dump .1,15.5,"SCISSORSLOGO" box 60,16,20,1 text 60,15.75,"$",10,univers text 65,16.5,"AMOUNT ENCLOSED",univers,7 erase 60,16,10,1 # middle section const HFONT=cgtimes,10,italic cbox 0,17.75,80,56 cbox 0,17.75,80,19.25,1,SHADE cbox 0,54,80,56 cbox 12,17.75,12,54 cbox 21,17.75,21,54 cbox 25,17.75,25,54 cbox 57,17.75,57,54 cbox 68,17.75,68,54 text 1,18.75,"Reference",HFONT,right,cols=11 text 12,18.75,"Date",HFONT,center,cols=10 text 21,18.75,"Code",HFONT,center,cols=4 text 26,18.75,"Description",HFONT text 57,18.75,"Amount",HFONT,right,cols=10 text 68,18.75,"Balance",HFONT,right,cols=12 cfont 26,20,56,54,cgtimes,9 text 58,55,"TOTAL DUE",12,univers,shade 0 cbox 57,54,68,56,1,100 cbold 69,55,MAXCOLS,55 text 2,54.5,"Codes:",cgtimes,7 text 10,54.5,"C = CR Memo",cgtimes,7 text 10,55.5,"D = DR Memo",cgtimes,7 text 20,54.5,"P = Payment",cgtimes,7 text 20,55.5,"I = Invoice",cgtimes,7 text 30,54.5,"F = Finance Charge",cgtimes,7 # bottom section cbox 0,56,63,58,1,SHADE cbox 0,58,63,60 box 15,56,1,4 box 31,56,1,4 box 47,56,1,4 erase 0,57,80,1 text 1,57,"Current",HFONT,right,cols=14 text 15,57,"Over 30",HFONT,right,cols=16 text 31,57,"Over 60",HFONT,right,cols=16 text 47,57,"Over 90",HFONT,right,cols=16 cbold 1,59,63,60 [AR Generic] # This rule set will set columns & rows and enhance the heading for other AR reports detect 1,1,"AR" detect 0,1,"Page" cols 132 rows 66 # copy 1 is generic 80 column, copy 2 is generic 132 column pcopies 2 prepage { maxlen=80 for i=1 to 66 if len(text$[i])>maxlen then maxlen=len(text$[i]) next i pgmname$=trim(get(1,1,10)) x=pos("Page"=text$[1]) compname$=trim(get(11,1,x-1-10)) pageno$=trim(get(x,1,11)) a=mask("","..:..:..") a=mask(text$[2]) title$=trim(get(1,2,a-1)) time$=trim(get(a,2,8)) rptdate$=trim(get(a+8,2,11)) } precopy { if maxlen>132 then skip=1 if copy=1 and maxlen>80 then skip=1 if copy=2 and maxlen=80 then skip=1 } # header const HFONT=univers,9,bold cerase 1,1,132,2 if copy 1 const MAXCOLS=80 const MAXRCOLS=79 cols MAXCOLS box .1,.1,80.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif if copy 2 const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif ############################### # Module: Bank Reconciliation # ############################### [BR Generic] # This rule set will set columns & rows and enhance the heading for other BR reports detect 1,1,"BR" detect 0,1,"Page" cols 132 rows 66 # copy 1 is generic 80 column, copy 2 is generic 132 column pcopies 2 prepage { maxlen=80 for i=1 to 66 if len(text$[i])>maxlen then maxlen=len(text$[i]) next i pgmname$=trim(get(1,1,10)) x=pos("Page"=text$[1]) compname$=trim(get(11,1,x-1-10)) pageno$=trim(get(x,1,11)) a=mask("","..:..:..") a=mask(text$[2]) title$=trim(get(1,2,a-1)) time$=trim(get(a,2,8)) rptdate$=trim(get(a+8,2,11)) } precopy { if maxlen>132 then skip=1 if copy=1 and maxlen>80 then skip=1 if copy=2 and maxlen=80 then skip=1 } # header const HFONT=univers,9,bold cerase 1,1,132,2 if copy 1 const MAXCOLS=80 const MAXRCOLS=79 cols MAXCOLS box .1,.1,80.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif if copy 2 const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif ################### # Module: Billing # ################### [BI Invoice] detect 0,3,"INVOICE-UDL" detect 75,6,"~../../.." #detect 61,7,"~[A-Za-z]" const MAXCOLS=90 const MAXRCOLS=89 cols MAXCOLS rows 66 pcopies 1 prepage { # Appgen inserts a blank line on some forms after first page, so shift up one line as needed # trash$=trim(text$[1]); \ # if trash$="" then \ # for i=2 to 66; \ # text$[i-1]=text$[i]; \ # text$[i]=""; \ # next i title$="INVOICE-UDL" dt$=trim(get(75,6,8)) inv$=trim(get(62,6,10)) cust$=trim(get(61,8,12)) pg$=trim(get(81,8,6)) subtotal$=trim(get(77,52,14)) dischd$=trim(get(53,54,20)) discamt$=trim(get(77,54,14)) if num(discamt$)=0 then discamt$="";dischd$="" taxhd$=trim(get(53,55,20)) taxamt$=trim(get(77,55,14)) if num(taxamt$)=0 then taxamt$="";taxhd$="" # mischd$="Miscellaneous" # miscamt$=trim(get(77,57,14)) # if num(miscamt$)=0 then miscamt$="";mischd$="" shiphd$="Shipping & Handling" shipamt$=trim(get(77,57,14)) if num(shipamt$)=0 then shipamt$="0.00" total$=trim(get(77,58,14)) } if copy 1 text 1,4,"Customer Copy",univers,12,bold,right,cols=MAXRCOLS endif if copy 2 text 1,4,"Accounting Copy",univers,12,bold,right,cols=MAXRCOLS endif # Title area cbox 1,1,MAXCOLS,66 cbox 1,1,MAXCOLS,8.5 erase 1,1,MAXCOLS,8 text 1,2.25,{title$},univers,18,bold,right,cols=MAXRCOLS if driver pdf # image 1,1,12,6,"COMP_PDFLOGO" endif if driver laser # image 1,1,12,6,"COMP_PCLLOGO" endif text 1,2.25,"COMP_NAME",univers,15,bold,center,cols=MAXCOLS text 1,3.35,"COMP_ADDR1",univers,12,center,cols=MAXCOLS text 1,4.35,"COMP_ADDR2",univers,12,center,cols=MAXCOLS text 1,5.35,"COMP_PHONES",univers,12,center,cols=MAXCOLS # Invoice block const HFONT=cgtimes,10,italic const DFONT=cgtimes,10,bold const SHADE=10 cbox 69,4.5,MAXCOLS,8.5 cbox 69,4.5,80,8.5,1,SHADE cbox 69,5.5,MAXCOLS,5.5 cbox 69,6.5,MAXCOLS,6.5 cbox 69,7.5,MAXCOLS,7.5 text 70,5,"Date",HFONT text 70,6,"Invoice No.",HFONT text 70,7,"Page No.",HFONT text 70,8,"Customer Code",HFONT #text 83,5,"05/29/02",DFONT,bold text 81,5,{dt$},DFONT,bold text 81,6,{inv$},DFONT,bold #text 83,7,"ABCDEFGHIJK",DFONT,bold text 81,7,{pg$},DFONT,bold text 81,8,{cust$},DFONT,bold # address sections cbox 1,8.5,MAXCOLS,13.5 cbox 1,8.5,10,13.5,1,SHADE cbox 52,8.5,61,13.5,1,SHADE text 2,9,"Bill To:",HFONT text 53,9,"Ship To:",HFONT cfont 11,9,45,13,DFONT cfont 62,9,96,13,DFONT # ribbon info cbox 1,15.5,MAXCOLS,16.5,1,SHADE cbox 1,16.5,MAXCOLS,17.5 cbox 38.5,15.5,38.5,17.5 cbox 42.5,15.5,42.5,17.5 cbox 59.5,15.5,59.5,17.5 cbox 69.5,15.5,69.5,17.5 cbox 74.5,15.5,74.5,17.5 text 2,16,"Customer PO",HFONT text 40,16,"SM",HFONT text 44,16,"Payment Terms",HFONT text 61,16,"Ship Date",HFONT,center,cols=8 text 71,16,"Frt",HFONT text 76,16,"Shipped Via",HFONT cfont 1,17,10,17,DFONT cfont 13,17,20,17,DFONT,center,cols=8 cfont 23,17,37,17,DFONT cfont 40,17,41,17,DFONT cfont 44,17,58,17,DFONT cfont 61,17,68,17,DFONT,center,cols=8 cfont 71,17,73,17,DFONT cfont 76,17,95,17,DFONT # line detail cbox 1,17.5,MAXCOLS,19.5,1,SHADE cbox 1,19.5,MAXCOLS,57 cbox 14,17.5,14,57 cbox 28,17.5,28,57 cbox 66,17.5,66,57 cbox 69,17.5,69,57 cbox 82,17.5,82,57 text 1,18,"Qty",HFONT,right,cols=12 text 1,19,"Ordered",HFONT,right,cols=12 text 16,19,"Code",HFONT text 29,19,"Description",HFONT text 67,19,"UM",HFONT,center,cols=2 text 70,19,"Unit Price",HFONT,right,cols=11 text 83,19,"Extension",HFONT,right,cols=14 cfont 1,20,12,57,DFONT,right,cols=10 cfont 29,20,65,57,DFONT cfont 83,20,96,57,DFONT,right,cols=12 # message area and totals cerase 59,52,MAXCOLS,60 cbox 59,57,80.5,66,1,SHADE cbox 80.5,57,MAXCOLS,66 cbox 59,59,MAXCOLS,59 cbox 59,60.5,MAXCOLS,60.5 cbox 59,61.5,MAXCOLS,61.5 cbox 59,62.5,MAXCOLS,62.5 cbox 59,63.5,MAXCOLS,63.5 text 60,58,"Subtotal",HFONT text 83,58,{subtotal$},DFONT,right,cols=14 text 60,60,{dischd$},HFONT text 83,60,{discamt$},DFONT,right,cols=14 text 60,61,{taxhd$},HFONT text 83,61,{taxamt$},DFONT,right,cols=14 text 60,62,{mischd$},HFONT text 83,62,{miscamt$},DFONT,right,cols=14 text 60,63,{shiphd$},HFONT text 83,63,{shipamt$},DFONT,right,cols=14 text 60,65,"TOTAL",univers,12,bold text 83,65,{total$},univers,12,bold,right,cols=14 [BI Generic] # This rule set will set columns & rows and enhance the heading for other BI reports detect 1,1,"BI" detect 0,1,"Page" cols 132 rows 66 # copy 1 is generic 80 column, copy 2 is generic 132 column pcopies 2 prepage { maxlen=80 for i=1 to 66 if len(text$[i])>maxlen then maxlen=len(text$[i]) next i pgmname$=trim(get(1,1,10)) x=pos("Page"=text$[1]) compname$=trim(get(11,1,x-1-10)) pageno$=trim(get(x,1,11)) a=mask("","..:..:..") a=mask(text$[2]) title$=trim(get(1,2,a-1)) time$=trim(get(a,2,8)) rptdate$=trim(get(a+8,2,11)) } precopy { if maxlen>132 then skip=1 if copy=1 and maxlen>80 then skip=1 if copy=2 and maxlen=80 then skip=1 } # header const HFONT=univers,9,bold cerase 1,1,132,2 if copy 1 const MAXCOLS=80 const MAXRCOLS=79 cols MAXCOLS box .1,.1,80.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif if copy 2 const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif ############################# # Module: Bill of Materials # ############################# [BM Generic] # This rule set will set columns & rows and enhance the heading for other BM reports detect 1,1,"BM" detect 0,1,"Page" cols 132 rows 66 # copy 1 is generic 80 column, copy 2 is generic 132 column pcopies 2 prepage { maxlen=80 for i=1 to 66 if len(text$[i])>maxlen then maxlen=len(text$[i]) next i pgmname$=trim(get(1,1,10)) x=pos("Page"=text$[1]) compname$=trim(get(11,1,x-1-10)) pageno$=trim(get(x,1,11)) a=mask("","..:..:..") a=mask(text$[2]) title$=trim(get(1,2,a-1)) time$=trim(get(a,2,8)) rptdate$=trim(get(a+8,2,11)) } precopy { if maxlen>132 then skip=1 if copy=1 and maxlen>80 then skip=1 if copy=2 and maxlen=80 then skip=1 } # header const HFONT=univers,9,bold cerase 1,1,132,2 if copy 1 const MAXCOLS=80 const MAXRCOLS=79 cols MAXCOLS box .1,.1,80.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif if copy 2 const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif ########################## # Module: General Ledger # ########################## [GL Balance Sheet] detect 0,2,"Balance Sheet" const MAXCOLS=123 const MAXRCOLS=122 cols MAXCOLS rows 66 pcopies 1 prepage { test$=trim(get(1,1,MAXCOLS)) if test$="" then \ for i=2 to 66; \ text$[i-1]=text$[i]; \ next i; \ text$[66]="" compname$=trim(get(45,1,40)) title$=trim(get(45,2,40)) rptdate$=trim(get(45,3,40)) } # header cerase 1,1,MAXCOLS,3 cbox .1,.1,132.9,3.5,3,20 text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,3.5,{rptdate$},univers,12,bold,center,cols=MAXCOLS const HFONT=cgtimes,10 font 40,6,11,1,HFONT,right,cols=11 font 89,6,11,1,HFONT,right,cols=11 font 43,7,8,1,HFONT,right,cols=8 font 92,7,8,1,HFONT,right,cols=8 # body box "----------------",0,0,16,1 erase "----------------",0,0,16,1 const DFONT=cgtimes,10,bold font "~[A-Z]@1,10,1,66",0,0,33,1,cgtimes,11,bold font "~ [A-Z]@1,10,3,66",0,0,32,1,cgtimes,10 font "~ [A-Z]@1,10,5,66",0,0,40,1,cgtimes,12,bold cfont 38,10,50,66,DFONT,right,cols=13 cfont 62,10,74,66,DFONT,right,cols=13 cfont 86,10,98,66,DFONT,right,cols=13 cfont 110,10,122,66,DFONT,right,cols=13 box "Total Assets",-.9,-1,123,2,5,10 font "Total Assets",0,0,40,1,cgtimes,12,bold erase "Total Assets",0,-1,MAXCOLS,1 erase "Total Assets",0,1,MAXCOLS,1 box "Total Liabilities & Stock",-.9,-1,123,2,5,10 font "Total Liabilities & Stock",0,0,40,1,cgtimes,12,bold erase "Total Liabilities & Stock",0,-1,MAXCOLS,1 erase "Total Liabilities & Stock",0,1,MAXCOLS,1 [GL Income Statement] detect 0,2,"Income Statement" const MAXCOLS=130 const MAXRCOLS=129 cols MAXCOLS rows 66 pcopies 1 prepage { compname$=trim(get(45,1,40)) title$=trim(get(45,2,40)) rptdate$=trim(get(45,3,40)) } # header cerase 1,1,MAXCOLS,3 cbox .1,.1,132.9,3.5,3,20 text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,3.5,{rptdate$},univers,12,bold,center,cols=MAXCOLS const HFONT=cgtimes,10 font 39,6,12,1,HFONT,right,cols=12 font 88,6,12,1,HFONT,right,cols=12 font 43,7,8,1,HFONT,right,cols=8 font 92,7,8,1,HFONT,right,cols=8 # body box "----------------",0,0,16,1 erase "----------------",0,0,16,1 const DFONT=cgtimes,10,bold font "~[A-Z]@1,10,1,66",0,0,33,1,cgtimes,11,bold font "~ [A-Z]@1,10,3,66",0,0,32,1,cgtimes,10 cfont 38,10,50,66,DFONT,right,cols=13 cfont 52,10,57,66,DFONT,right,cols=6 cfont 62,10,74,66,DFONT,right,cols=13 cfont 76,10,81,66,DFONT,right,cols=6 cfont 86,10,98,66,DFONT,right,cols=13 cfont 101,10,106,66,DFONT,right,cols=6 cfont 110,10,122,66,DFONT,right,cols=13 cfont 124,10,129,66,DFONT,right,cols=6 box "Net Income ",-.9,-1,130,2,5,10 font "Net Income ",0,0,40,1,cgtimes,12,bold erase "Net Income ",0,-1,MAXCOLS,1 erase "Net Income ",0,1,MAXCOLS,1 [GL Schedule] detect 0,2,"Schedule" const MAXCOLS=124 const MAXRCOLS=123 cols MAXCOLS rows 66 pcopies 1 prepage { compname$=trim(get(40,1,50)) title$=trim(get(40,2,50)) title1$=trim(get(40,3,50)) rptdate$=trim(get(40,4,50)) } # header cerase 1,1,MAXCOLS,4 cbox .1,.1,MAXCOLS,5,3,20 text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,3.5,{title1$},univers,12,bold,center,cols=MAXCOLS text 1,4.5,{rptdate$},univers,12,bold,center,cols=MAXCOLS const HFONT=cgtimes,10 font 63,6,12,1,HFONT,right,cols=12 font 113,6,12,1,HFONT,right,cols=12 font 67,7,8,1,HFONT,right,cols=8 font 117,7,8,1,HFONT,right,cols=8 # body const DFONT=cgtimes,10,bold cfont 1,10,35,66,cgtimes,10,bold cfont 62,10,74,66,DFONT,right,cols=13 cfont 110,10,122,66,DFONT,right,cols=13 box "Total",-.9,-1,MAXCOLS,2,5,10 font "Total",0,0,40,1,cgtimes,12,bold erase "Total",0,-1,MAXCOLS,1 erase "Total",0,1,MAXCOLS,1 [GL Trial Balance] detect 0,4,"Trial Balance (" const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS rows 66 pcopies 1 prepage { compname$=trim(get(45,1,50)) title$=trim(get(45,4,50)) title1$=trim(get(45,5,50)) pgmname$=trim(get(1,1,10)) pageno$=trim(get(124,1,13)) time$=trim(get(113,2,8)) rptdate$=trim(get(122,2,11)) } # header const HFONT=univers,9,bold cerase 1,1,MAXCOLS,5 cbox .1,.1,132.9,4,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,3.5,{title1$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT const HFONT=cgtimes,10 cmove 1,7,60,8,2,7 cfont 2,7,20,7,HFONT cfont 23,7,46,8,HFONT,right,cols=24 cfont 49,7,62,8,HFONT,bold cfont 65,7,85,8,HFONT,right,cols=21 cfont 88,7,98,8,HFONT,bold # body const HFONT=cgtimes,10,italic const DFONT=cgtimes,9 cbox 0.1,9,MAXCOLS,11,1,10 cerase 1,10,MAXCOLS,11 text 1,10,"Account #",HFONT text 13,10,"Description",HFONT text 46,10,"Opening Balance",HFONT,right,cols=14 text 64,10,"Total Debits",HFONT,right,cols=14 text 82,10,"Total Credits",HFONT,right,cols=14 text 100,10,"Net Change",HFONT,right,cols=14 text 118,10,"Closing Balance",HFONT,right,cols=14 shade 1,12,MAXCOLS,3,1,3,9 cfont 1,12,10,66,DFONT cfont 13,12,42,66,DFONT ##### To increase speed, make the following lines remarks (#) cfont 46,12,59,66,DFONT,right,cols=14,black cfont 64,12,77,66,DFONT,right,cols=14 cfont 82,12,95,66,DFONT,right,cols=14,black cfont 100,12,113,66,DFONT,right,cols=14 cfont 118,12,131,66,DFONT,bold,right,cols=14,black # totals erase "Grand Totals",0,-1,MAXCOLS,1 font "Grand Totals",0,0,20,1,HFONT,bold box "Grand Totals",-2,-1,113,2,5,10 bold "Grand Totals",0,0,113,1 [GL Generic] # This rule set will set columns & rows and enhance the heading for other GL reports detect 1,1,"GL" detect 0,1,"Page" cols 132 rows 66 # copy 1 is generic 80 column, copy 2 is generic 132 column pcopies 2 prepage { maxlen=80 for i=1 to 66 if len(text$[i])>maxlen then maxlen=len(text$[i]) next i pgmname$=trim(get(1,1,10)) x=pos("Page"=text$[1]) compname$=trim(get(11,1,x-1-10)) pageno$=trim(get(x,1,11)) a=mask("","..:..:..") a=mask(text$[2]) title$=trim(get(1,2,a-1)) time$=trim(get(a,2,8)) rptdate$=trim(get(a+8,2,11)) } precopy { if maxlen>132 then skip=1 if copy=1 and maxlen>80 then skip=1 if copy=2 and maxlen=80 then skip=1 } # header const HFONT=univers,9,bold cerase 1,1,132,2 if copy 1 const MAXCOLS=80 const MAXRCOLS=79 cols MAXCOLS box .1,.1,80.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif if copy 2 const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif ############################# # Module: Inventory Control # ############################# [IV Generic] # This rule set will set columns & rows and enhance the heading for other IV reports detect 1,1,"IV" detect 0,1,"Page" cols 132 rows 66 # copy 1 is generic 80 column, copy 2 is generic 132 column pcopies 2 prepage { maxlen=80 for i=1 to 66 if len(text$[i])>maxlen then maxlen=len(text$[i]) next i pgmname$=trim(get(1,1,10)) x=pos("Page"=text$[1]) compname$=trim(get(11,1,x-1-10)) pageno$=trim(get(x,1,11)) a=mask("","..:..:..") a=mask(text$[2]) title$=trim(get(1,2,a-1)) time$=trim(get(a,2,8)) rptdate$=trim(get(a+8,2,11)) } precopy { if maxlen>132 then skip=1 if copy=1 and maxlen>80 then skip=1 if copy=2 and maxlen=80 then skip=1 } # header const HFONT=univers,9,bold cerase 1,1,132,2 if copy 1 const MAXCOLS=80 const MAXRCOLS=79 cols MAXCOLS box .1,.1,80.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif if copy 2 const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif ############################# # Module: Job Cost Tracking # ############################# [JC Generic] # This rule set will set columns & rows and enhance the heading for other JC reports detect 1,1,"JC" detect 0,1,"Page" cols 132 rows 66 # copy 1 is generic 80 column, copy 2 is generic 132 column pcopies 2 prepage { maxlen=80 for i=1 to 66 if len(text$[i])>maxlen then maxlen=len(text$[i]) next i pgmname$=trim(get(1,1,10)) x=pos("Page"=text$[1]) compname$=trim(get(11,1,x-1-10)) pageno$=trim(get(x,1,11)) a=mask("","..:..:..") a=mask(text$[2]) title$=trim(get(1,2,a-1)) time$=trim(get(a,2,8)) rptdate$=trim(get(a+8,2,11)) } precopy { if maxlen>132 then skip=1 if copy=1 and maxlen>80 then skip=1 if copy=2 and maxlen=80 then skip=1 } # header const HFONT=univers,9,bold cerase 1,1,132,2 if copy 1 const MAXCOLS=80 const MAXRCOLS=79 cols MAXCOLS box .1,.1,80.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif if copy 2 const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif ############################## # Module: Payroll Processing # ############################## [PR Checks] # Using plain paper detect 65,18,"~../../.." detect 68,26,"~../../.." const MAXCOLS=86 const MAXRCOLS=85 cols MAXCOLS page 42 rows 66 pcopies 2 prepage { # load up check data for later placement chkno$=trim(get(77,26,7)) chkdate$=trim(get(1,26,75));x$=set(1,26,MAXCOLS,"") chkamt$=trim(get(1,29,85));x$=set(1,29,MAXCOLS,"") chkamt_words$=trim(get(1,31,85));x$=set(1,31,85,"") name$=trim(get(1,33,81));x$=set(1,33,81,"") addr1$=trim(get(1,34,81));x$=set(1,34,81,"") addr2$=trim(get(1,35,81));x$=set(1,35,81,"") addr3$=trim(get(1,36,81));x$=set(1,36,81,"") } precopy { if copy=1 and copy<>PR_NO_STUBS then skip=1 if copy=2 and copy<>PR_NO_STUBS then skip=1 } const SHFONT=cgtimes,9,shade 0 const DFONT=cgtimes,10,bold const HFONT=cgtimes,9,italic # top stub - employer's if copy 1 cerase 1,1,MAXCOLS,22 endif if copy 2 text 64,3,"Check Number",cgtimes,12,italic text 76,3,{chkno$},cgtimes,18,bold erase 1,3,MAXCOLS,1 cbox 3,3.5,84,4.5,1,100 cbox 3,4.5,84,6.5 cbox 3,6.5,84,8.5 text 5,4,"EMP#",SHFONT font 5,6,5,1,DFONT text 6,7,"Social Security #",HFONT font 6,8,11,1,DFONT,black text 10,4,"HOURS",SHFONT,center,cols=30 cbox 9.5,4.5,9.5,6.5 text 10,5,"Regular",HFONT,right,cols=7 font 10,6,7,1,DFONT,right,cols=7,black cbox 17,4.5,17,8.5 text 17,5,"Overtime",HFONT,right,cols=7 font 18,6,6,1,DFONT,right,cols=7 text 17,7,"Vacation",HFONT,right,cols=7 font 18,8,6,1,DFONT,right,cols=7 cbox 24,4.5,24,8.5 text 25,5,"Holiday",HFONT,right,cols=7 font 25,6,7,1,DFONT,right,cols=7,black text 25,7,"Sick",HFONT,right,cols=7 font 25,8,7,1,DFONT,right,cols=7,black cbox 32,4.5,32,8.5 text 33,5,"Special",HFONT,right,cols=7 font 33,6,7,1,DFONT,right,cols=7 text 33,7,"Total",HFONT,right,cols=7 font 33,8,7,1,DFONT,right,cols=7 text 40,4,"EARNINGS",SHFONT,center,cols=43 cbox 40,4.5,40,8.5,3 text 41,5,"Regular",HFONT,right,cols=9 font 41,6,9,1,DFONT,right,cols=9,black text 41,7,"Vacation",HFONT,right,cols=9 font 41,8,9,1,DFONT,right,cols=9,black cbox 50,4.5,50,8.5 text 51,5,"Overtime",HFONT,right,cols=8 font 51,6,8,1,DFONT,right,cols=8 text 51,7,"Sick",HFONT,right,cols=8 font 51,8,8,1,DFONT,right,cols=8 cbox 59,4.5,59,8.5 text 60,5,"Bonus",HFONT,right,cols=8 font 60,6,8,1,DFONT,right,cols=8,black cbox 68,4.5,68,8.5 text 60,7,"Commission",HFONT,right,cols=8 font 60,8,8,1,DFONT,right,cols=8 cbox 73,4.5,73,8.5 text 74,7,"Gross Pay",HFONT,right,cols=10 font 74,8,10,1,DFONT,right,cols=10,black cbox 3,9.5,84,10.5,1,100 text 4,10,"TAXES",SHFONT,center,cols=26 cbox 3,10.5,84,12.5 cbox 3,12.5,84,14.5 text 5,11,"FICA",HFONT,right,cols=9 font 5,12,9,1,DFONT,right,cols=9 text 5,13,"FIT",HFONT,right,cols=9 font 5,14,9,1,DFONT,right,cols=9 cbox 14,10,14,14.5 text 15,11,"SIT",HFONT,right,cols=7 font 15,12,7,1,DFONT,right,cols=7,black font 15,13,7,1,HFONT,right,cols=7 font 15,14,7,1,DFONT,right,cols=7,black cbox 22,10,22,14.5 font 23,11,8,1,HFONT,right,cols=7 font 23,12,8,1,DFONT,right,cols=7 text 23,13,"Total",HFONT,right,cols=8 font 23,14,8,1,DFONT,right,cols=7 text 31,10,"DEDUCTIONS",SHFONT,center,cols=54 cbox 30.75,10,30.75,14.5,3 text 31,11,"Med Ins",HFONT,right,cols=7,black font 31,12,7,1,DFONT,right,cols=7,black font 31,13,7,1,HFONT,right,cols=7,black font 31,14,7,1,DFONT,right,cols=7,black cbox 38,10,38,14.5 font 39,11,7,1,HFONT,right,cols=7 font 39,12,7,1,DFONT,right,cols=7 font 39,13,7,1,HFONT,right,cols=7 font 39,14,7,1,DFONT,right,cols=7 cbox 45.75,10,45.75,14.5 font 46,11,7,1,HFONT,right,cols=7,black font 46,12,7,1,DFONT,right,cols=7,black font 46,13,7,1,HFONT,right,cols=7,black font 46,14,7,1,DFONT,right,cols=7,black cbox 53.75,10,53.75,14.5 font 54,11,7,1,HFONT,right,cols=7 font 54,12,7,1,DFONT,right,cols=7 font 54,13,7,1,HFONT,right,cols=7 font 54,14,7,1,DFONT,right,cols=7 cbox 61,10,61,14.5 font 62,11,7,1,HFONT,right,cols=7,black font 62,12,7,1,DFONT,right,cols=7,black font 62,13,7,1,HFONT,right,cols=7,black font 62,14,7,1,DFONT,right,cols=7,black cbox 68.75,10,68.75,14.5 font 69,11,7,1,HFONT,right,cols=7 font 69,12,7,1,DFONT,right,cols=7 font 69,13,7,1,HFONT,right,cols=7 font 69,14,7,1,DFONT,right,cols=7 cbox 76,10,76,14.5 font 77,11,7,1,HFONT,right,cols=7 font 77,12,7,1,DFONT,right,cols=7 text 77,13,"Total",HFONT,right,cols=7 font 77,14,7,1,DFONT,right,cols=7 cbox 3,15.5,61,16.5,1,100 text 3,16,"YEAR TO DATE",SHFONT,center,cols=58 cbox 3,16.5,61,18.5 cbox 16,16.5,16,18.5 cbox 25,16.5,25,18.5 cbox 35,16.5,35,18.5 cbox 45,16.5,45,18.5 cbox 54,16.5,54,18.5 text 3,17,"Gross Pay",HFONT,right,cols=13 font 3,18,13,1,DFONT,right,cols=13 text 16,17,"FICA",HFONT,right,cols=9 font 16,18,9,1,DFONT,right,cols=9,black text 25,17,"FIT",HFONT,right,cols=10 font 25,18,10,1,DFONT,right,cols=10 text 35,17,"SIT",HFONT,right,cols=10 font 35,18,10,1,DFONT,right,cols=10,black font 45,17,15,1,HFONT,center,cols=15 font 45,18,9,1,DFONT,right,cols=9 font 55,18,6,1,DFONT,right,cols=6,black cbox 64,16,72.75,17.5,1,100 cbox 73,16,84,17.5,1,100 text 64,17,"PAY PERIOD",SHFONT,center,cols=10 text 73,17,"NET PAY",SHFONT,right,cols=11 cbox 64,17.5,72.75,18.5 font 65,18,8,1,DFONT,center,cols=8 cbox 73,17.5,84,18.5 font 73,18,11,1,DFONT,right,cols=11 text 5,21,"COMP_NAME",univers,15,bold text 73,21,"Employer Copy",DFONT cbox 1,22.5,MAXCOLS,22.5 endif # Middle stub - employee's cmove 1,1,MAXCOLS,22,1,23,1 text 64,25,"Check Number",cgtimes,12,italic text 76,25,{chkno$},cgtimes,18,bold erase 1,25,MAXCOLS,1 cbox 3,25.5,84,26.5,1,100 cbox 3,26.5,84,28.5 cbox 3,28.5,84,30.5 text 5,26,"EMP#",SHFONT font 5,28,5,1,DFONT text 6,29,"Social Security #",HFONT font 6,30,11,1,DFONT,black text 10,26,"HOURS",SHFONT,center,cols=30 cbox 9.5,26.5,9.5,28.5 text 10,27,"Regular",HFONT,right,cols=7 font 10,28,7,1,DFONT,right,cols=7,black cbox 17,26.5,17,30.5 text 17,27,"Overtime",HFONT,right,cols=7 font 18,28,6,1,DFONT,right,cols=7 text 17,29,"Vacation",HFONT,right,cols=7 font 18,30,6,1,DFONT,right,cols=7 cbox 24,26.5,24,30.5 text 25,27,"Holiday",HFONT,right,cols=7 font 25,28,7,1,DFONT,right,cols=7,black text 25,29,"Sick",HFONT,right,cols=7 font 25,30,7,1,DFONT,right,cols=7,black cbox 32,26.5,32,30.5 text 33,27,"Special",HFONT,right,cols=7 font 33,28,7,1,DFONT,right,cols=7 text 33,29,"Total",HFONT,right,cols=7 font 33,30,7,1,DFONT,right,cols=7 text 40,26,"EARNINGS",SHFONT,center,cols=43 cbox 40,26.5,40,30.5,3 text 41,27,"Regular",HFONT,right,cols=9 font 41,28,9,1,DFONT,right,cols=9,black text 41,29,"Vacation",HFONT,right,cols=9 font 41,30,9,1,DFONT,right,cols=9,black cbox 50,26.5,50,30.5 text 51,27,"Overtime",HFONT,right,cols=8 font 51,28,8,1,DFONT,right,cols=8 text 51,29,"Sick",HFONT,right,cols=8 font 51,30,8,1,DFONT,right,cols=8 cbox 59,26.5,59,30.5 text 60,27,"Bonus",HFONT,right,cols=8 font 60,28,8,1,DFONT,right,cols=8,black cbox 68,26.5,68,30.5 text 60,29,"Commission",HFONT,right,cols=8 font 60,30,8,1,DFONT,right,cols=8 cbox 73,26.5,73,30.5 text 74,29,"Gross Pay",HFONT,right,cols=10 font 74,30,10,1,DFONT,right,cols=10,black cbox 3,31.5,84,32.5,1,100 text 4,32,"TAXES",SHFONT,center,cols=26 cbox 3,32.5,84,34.5 cbox 3,34.5,84,36.5 text 5,33,"FICA",HFONT,right,cols=9 font 5,34,9,1,DFONT,right,cols=9 text 5,35,"FIT",HFONT,right,cols=9 font 5,36,9,1,DFONT,right,cols=9 cbox 14,32,14,36.5 text 15,33,"SIT",HFONT,right,cols=7 font 15,34,7,1,DFONT,right,cols=7,black font 15,35,7,1,HFONT,right,cols=7 font 15,36,7,1,DFONT,right,cols=7,black cbox 22,32,22,36.5 font 23,33,8,1,HFONT,right,cols=7 font 23,34,8,1,DFONT,right,cols=7 text 23,35,"Total",HFONT,right,cols=8 font 23,36,8,1,DFONT,right,cols=7 text 31,32,"DEDUCTIONS",SHFONT,center,cols=54 cbox 30.75,32,30.75,36.5,3 text 31,33,"Med Ins",HFONT,right,cols=7,black font 31,34,7,1,DFONT,right,cols=7,black font 31,35,7,1,HFONT,right,cols=7,black font 31,36,7,1,DFONT,right,cols=7,black cbox 38,32,38,36.5 font 39,33,7,1,HFONT,right,cols=7 font 39,34,7,1,DFONT,right,cols=7 font 39,35,7,1,HFONT,right,cols=7 font 39,36,7,1,DFONT,right,cols=7 cbox 45.75,32,45.75,36.5 font 46,33,7,1,HFONT,right,cols=7,black font 46,34,7,1,DFONT,right,cols=7,black font 46,35,7,1,HFONT,right,cols=7,black font 46,36,7,1,DFONT,right,cols=7,black cbox 53.75,32,53.75,36.5 font 54,33,7,1,HFONT,right,cols=7 font 54,34,7,1,DFONT,right,cols=7 font 54,35,7,1,HFONT,right,cols=7 font 54,36,7,1,DFONT,right,cols=7 cbox 61,32,61,36.5 font 62,33,7,1,HFONT,right,cols=7,black font 62,34,7,1,DFONT,right,cols=7,black font 62,35,7,1,HFONT,right,cols=7,black font 62,36,7,1,DFONT,right,cols=7,black cbox 68.75,32,68.75,36.5 font 69,33,7,1,HFONT,right,cols=7 font 69,34,7,1,DFONT,right,cols=7 font 69,35,7,1,HFONT,right,cols=7 font 69,36,7,1,DFONT,right,cols=7 cbox 76,32,76,36.5 font 77,33,7,1,HFONT,right,cols=7 font 77,34,7,1,DFONT,right,cols=7 text 77,35,"Total",HFONT,right,cols=7 font 77,36,7,1,DFONT,right,cols=7 cbox 3,37.5,61,38.5,1,100 text 3,38,"YEAR TO DATE",SHFONT,center,cols=58 cbox 3,38.5,61,40.5 cbox 16,38.5,16,40.5 cbox 25,38.5,25,40.5 cbox 35,38.5,35,40.5 cbox 45,38.5,45,40.5 cbox 54,38.5,54,40.5 text 3,39,"Gross Pay",HFONT,right,cols=13 font 3,40,13,1,DFONT,right,cols=13 text 16,39,"FICA",HFONT,right,cols=9 font 16,40,9,1,DFONT,right,cols=9,black text 25,39,"FIT",HFONT,right,cols=10 font 25,40,10,1,DFONT,right,cols=10 text 35,39,"SIT",HFONT,right,cols=10 font 35,40,10,1,DFONT,right,cols=10,black font 45,39,15,1,HFONT,center,cols=15 font 45,40,9,1,DFONT,right,cols=9 font 55,40,6,1,DFONT,right,cols=6,black cbox 64,38,72.75,39.5,1,100 cbox 73,38,84,39.5,1,100 text 64,39,"PAY PERIOD",SHFONT,center,cols=10 text 73,39,"NET PAY",SHFONT,right,cols=11 cbox 64,39.5,72.75,40.5 font 65,40,8,1,DFONT,center,cols=8 cbox 73,39.5,84,40.5 font 73,40,11,1,DFONT,right,cols=11 text 5,43,"COMP_NAME",univers,15,bold text 73,43,"Employee Copy",DFONT # Check const SHFONT=cgtimes,11,shade 0 const DFONT=cgtimes,12,bold const HFONT=cgtimes,12,italic cbox 1,44.5,MAXCOLS,44.5 cbox 1,45,MAXCOLS,65,4,10 if driver pdf image 1,45.1,12,6,"COMP_PDFLOGO" endif if driver laser image 1,45.1,12,6,"COMP_PCLLOGO" endif text 15,47,"COMP_NAME",univers,15,bold text 15,48,"COMP_ADDR1",univers,12 text 15,49,"COMP_ADDR2",univers,12 text 64,47,"Check Number",HFONT text 76,47,{chkno$},cgtimes,18,bold cbox 55,49,65,50,1,100 cbox 55,50,65,51.5 text 56,49.5,"Date",SHFONT,shade 0,center,cols=9 text 56,51,{chkdate$},DFONT,center,cols=9 cbox 69,49,82,50,1,100 cbox 69,50,82,51.5 text 70,49.5,"Amount",SHFONT,shade 0,right,cols=12 text 70,51,{chkamt$},DFONT,right,cols=12 text 2,53.5,{chkamt_words$},DFONT,italic text 2,58,"Pay to the Order of",HFONT text 11,59,{name$},DFONT text 11,60,{addr1$},DFONT text 11,61,{addr2$},DFONT text 11,62,{addr3$},DFONT dump 50,63,SIGNATURE box 50,63.5,30,1,3 text 50,64.2,"Authorized Signature",HFONT,center,cols=30 micr 10,65,PR_MICR_ACCOUNTNO,{chkno$} [PR Generic] # This rule set will set columns & rows and enhance the heading for other PR reports detect 1,1,"PR" detect 0,1,"Page" cols 132 rows 66 # copy 1 is generic 80 column, copy 2 is generic 132 column pcopies 2 prepage { maxlen=80 for i=1 to 66 if len(text$[i])>maxlen then maxlen=len(text$[i]) next i pgmname$=trim(get(1,1,10)) x=pos("Page"=text$[1]) compname$=trim(get(11,1,x-1-10)) pageno$=trim(get(x,1,11)) a=mask("","..:..:..") a=mask(text$[2]) title$=trim(get(1,2,a-1)) time$=trim(get(a,2,8)) rptdate$=trim(get(a+8,2,11)) } precopy { if maxlen>132 then skip=1 if copy=1 and maxlen>80 then skip=1 if copy=2 and maxlen=80 then skip=1 } # header const HFONT=univers,9,bold cerase 1,1,132,2 if copy 1 const MAXCOLS=80 const MAXRCOLS=79 cols MAXCOLS box .1,.1,80.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif if copy 2 const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif ##################################### # Module: Purchase Order Processing # ##################################### [PO Purchase Order] # works for 35 or less detail lines # detect on date/po no/page no detect 73,2,"~../../.. [0-9][0-9][0-9]" detect 87,7,"~[0-9]" const MAXCOLS=96 const MAXRCOLS=95 cols MAXCOLS page 66 rows 66 pcopies 2 prepage { # Appgen inserts a blank line on some forms after first page, so shift up one line as needed trash$=trim(text$[2]) if trash$="" then \ for i=2 to 66; \ text$[i-1]=text$[i]; \ text$[i]=""; \ next i # get date and po to move to better location dt$=trim(get(73,2,8)) po$=trim(get(84,2,5)) pg$=trim(get(80,7,10)) # move total lines to bottom for i=22 to 60 if mid(text$[i],74,1)="." then \ subtotal_line$=text$[i-1]; \ text$[i-1]=""; \ tax_line$=text$[i]; \ text$[i]=""; \ freight_line$=text$[i+1]; \ text$[i+1]=""; \ misc_line$=text$[i+2]; \ text$[i+2]=""; \ line$=text$[i+3]; \ text$[i+3]=""; \ total_line$=text$[i+4]; \ text$[i+4]=""; \ text$[60]=subtotal_line$; \ text$[61]=tax_line$; \ text$[62]=freight_line$; \ text$[63]=misc_line$; \ text$[64]=line$; \ text$[65]=total_line$; \ exitto exit_loop next i exit_loop: } # Title area text 1,2.25,"Purchase Order",univers,18,bold,right,cols=MAXRCOLS if driver pdf image 1,1,12,6,"COMP_PDFLOGO" endif if driver laser image 1,1,12,6,"COMP_PCLLOGO" endif text 1,2.25,"COMP_NAME",univers,15,bold,center,cols=MAXCOLS text 1,3.35,"COMP_ADDR1",univers,12,center,cols=MAXCOLS text 1,4.35,"COMP_ADDR2",univers,12,center,cols=MAXCOLS text 1,5.35,"COMP_PHONES",univers,12,center,cols=MAXCOLS if copy 1 text 1,4.5,"Vendor Copy",univers,12,bold,right,cols=MAXRCOLS endif if copy 2 text 1,4.5,"Accounting Copy",univers,12,bold,right,cols=MAXRCOLS endif # PO block const HFONT=cgtimes,9,italic const SHADE=10 erase 73,2,20,6 cbox 70,5.5,82,8.5,1,SHADE cbox 82,5.5,96.5,8.5 cbox 70,6.5,96.5,6.5 cbox 70,7.5,96.5,7.5 text 71,6,"Date",HFONT text 71,7,"PO No.",HFONT text 71,8,"Page No.",HFONT text 83,6,{dt$},HFONT,bold text 83,7,{po$},HFONT,bold text 83,8,{pg$},HFONT,bold # address sections erase 14,9,10,1 cbox 1,8.5,96.5,9.5,1,SHADE cbox 1,9.5,96.5,16 cbox 50,8.5,50,16 text 14,9,"Vendor:",HFONT text 60,9,"Ship To:",HFONT # ribbon info cbox 1,16,96.5,17.5,1,SHADE cbox 1,17.5,96.5,19 cbox 22,16,22,19 cbox 32,16,32,19 cbox 50,16,50,19 cbox 75,16,75,19 text 2,17,"Your Sales Order",HFONT text 23,17,"Buyer",HFONT text 33,17,"Payment Terms",HFONT text 51,17,"F.O.B.",HFONT text 76,17,"Ship Via",HFONT # line detail cbox 1,19,96.5,21.5,1,SHADE cbox 1,21.5,96.5,59.5 cbox 12,19,12,59.5 cbox 33,19,33,59.5 cbox 64,19,64,59.5 cbox 73,19,73,59.5 cbox 76,19,76,59.5 cbox 86,19,86,59.5 text 2,21,"Qty Ordered",HFONT,right,cols=9 text 13,20,"Our Part No.",HFONT text 13,21,"Your Part No.",HFONT text 34,21,"Description",HFONT text 65,21,"Date Due",HFONT,center,cols=8 text 74,21,"UM",HFONT,center,cols=2 text 77,21,"Unit Price",HFONT,right,cols=9 text 87,21,"Extension",HFONT,right,cols=10 # message area and totals cbox 1,59.5,96.5,66 cbox 62,59.5,78.5,66,1,SHADE cbox 78.5,59.5,96.5,66 cbox 62,60.5,96.5,60.5 cbox 62,61.5,96.5,61.5 cbox 62,62.5,96.5,62.5 cbox 62,63.5,96.5,63.5 text 64,60,"Subtotal",HFONT text 64,61,"Tax %",HFONT font 70,61,10,1,HFONT text 64,62,"Freight",HFONT text 64,63,"Misc",HFONT text 64,65,"TOTAL",univers,12,bold font 87,65,10,1,univers,12,bold,right,cols=10 [PO Generic] # This rule set will set columns & rows and enhance the heading for other PO reports detect 1,1,"PO" detect 0,1,"Page" cols 132 rows 66 # copy 1 is generic 80 column, copy 2 is generic 132 column pcopies 2 prepage { maxlen=80 for i=1 to 66 if len(text$[i])>maxlen then maxlen=len(text$[i]) next i pgmname$=trim(get(1,1,10)) x=pos("Page"=text$[1]) compname$=trim(get(11,1,x-1-10)) pageno$=trim(get(x,1,11)) a=mask("","..:..:..") a=mask(text$[2]) title$=trim(get(1,2,a-1)) time$=trim(get(a,2,8)) rptdate$=trim(get(a+8,2,11)) } precopy { if maxlen>132 then skip=1 if copy=1 and maxlen>80 then skip=1 if copy=2 and maxlen=80 then skip=1 } # header const HFONT=univers,9,bold cerase 1,1,132,2 if copy 1 const MAXCOLS=80 const MAXRCOLS=79 cols MAXCOLS box .1,.1,80.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif if copy 2 const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif ################################## # Module: Sales Order Processing # ################################## [OE Invoice] detect 0,1,"~(INVOICE)|(CREDIT MEMO)" detect 80,4,"~../../.." const MAXCOLS=97 const MAXRCOLS=96 cols MAXCOLS rows 66 pcopies 2 prepage { # Appgen inserts a blank line on some forms after first page, so shift up one line as needed trash$=trim(text$[1]) if trash$="" then \ for i=2 to 66; \ text$[i-1]=text$[i]; \ text$[i]=""; \ next i title$=trim(get(1,1,MAXCOLS)) title$=trim(title$(4)) # remove leading *** title$=trim(title$(1,len(title$)-3)) # remove trailing *** dt$=trim(get(80,4,8)) inv$=trim(get(68,4,10)) cust$=trim(get(68,6,12)) pg$=trim(get(90,6,6)) subtotal$=trim(get(83,52,14)) dischd$=trim(get(60,54,20)) discamt$=trim(get(83,54,14)) if num(discamt$)=0 then discamt$="";dischd$="" taxhd$=trim(get(60,55,20)) taxamt$=trim(get(83,55,14)) if num(taxamt$)=0 then taxamt$="";taxhd$="" mischd$="Miscellaneous" miscamt$=trim(get(83,56,14)) if num(miscamt$)=0 then miscamt$="";mischd$="" shiphd$="Shipping & Handling" shipamt$=trim(get(83,57,14)) if num(shipamt$)=0 then shipamt$="0.00" total$=trim(get(83,60,14)) } if copy 1 text 1,4,"Customer Copy",univers,12,bold,right,cols=MAXRCOLS endif if copy 2 text 1,4,"Accounting Copy",univers,12,bold,right,cols=MAXRCOLS endif # Title area cbox 1,1,MAXCOLS,66 cbox 1,1,MAXCOLS,8.5 erase 1,1,MAXCOLS,6 text 1,2.25,{title$},univers,18,bold,right,cols=MAXRCOLS if driver pdf image 1,1,12,6,"COMP_PDFLOGO" endif if driver laser image 1,1,12,6,"COMP_PCLLOGO" endif text 1,2.25,"COMP_NAME",univers,15,bold,center,cols=MAXCOLS text 1,3.35,"COMP_ADDR1",univers,12,center,cols=MAXCOLS text 1,4.35,"COMP_ADDR2",univers,12,center,cols=MAXCOLS text 1,5.35,"COMP_PHONES",univers,12,center,cols=MAXCOLS # Invoice block const HFONT=cgtimes,10,italic const DFONT=cgtimes,10,bold const SHADE=10 cbox 70,4.5,MAXCOLS,8.5 cbox 70,4.5,82,8.5,1,SHADE cbox 70,5.5,MAXCOLS,5.5 cbox 70,6.5,MAXCOLS,6.5 cbox 70,7.5,MAXCOLS,7.5 text 71,5,"Date",HFONT text 71,6,"Invoice No.",HFONT text 71,7,"Page No.",HFONT text 71,8,"Customer Code",HFONT text 83,5,{dt$},DFONT,bold text 83,6,{inv$},DFONT,bold text 83,7,{pg$},DFONT,bold text 83,8,{cust$},DFONT,bold # address sections cbox 1,8.5,MAXCOLS,13.5 cbox 1,8.5,10,13.5,1,SHADE cbox 52,8.5,61,13.5,1,SHADE text 2,9,"Bill To:",HFONT text 53,9,"Ship To:",HFONT cfont 11,9,45,13,DFONT cfont 62,9,96,13,DFONT # ribbon info cbox 1,15.5,MAXCOLS,16.5,1,SHADE cbox 1,16.5,MAXCOLS,17.5 cbox 11.5,15.5,11.5,17.5 cbox 21.5,15.5,21.5,17.5 cbox 38.5,15.5,38.5,17.5 cbox 42.5,15.5,42.5,17.5 cbox 59.5,15.5,59.5,17.5 cbox 69.5,15.5,69.5,17.5 cbox 74.5,15.5,74.5,17.5 text 2,16,"Order #",HFONT text 13,16,"Order Date",HFONT,center,cols=8 text 23,16,"Customer PO",HFONT text 40,16,"SM",HFONT text 44,16,"Payment Terms",HFONT text 61,16,"Ship Date",HFONT,center,cols=8 text 71,16,"Frt",HFONT text 76,16,"Shipped Via",HFONT cfont 1,17,10,17,DFONT cfont 13,17,20,17,DFONT,center,cols=8 cfont 23,17,37,17,DFONT cfont 40,17,41,17,DFONT cfont 44,17,58,17,DFONT cfont 61,17,68,17,DFONT,center,cols=8 cfont 71,17,73,17,DFONT cfont 76,17,95,17,DFONT # line detail cbox 1,17.5,MAXCOLS,19.5,1,SHADE cbox 1,19.5,MAXCOLS,57 cbox 11.5,17.5,11.5,57 cbox 23.5,17.5,23.5,57 cbox 35.5,17.5,35.5,57 cbox 67,17.5,67,57 cbox 70,17.5,70,57 cbox 76,17.5,76,57 cbox 86,17.5,86,57 text 1,18,"Qty",HFONT,right,cols=10 text 1,19,"Ordered",HFONT,right,cols=10 text 13,18,"Qty",HFONT,right,cols=10 text 13,19,"Shipped",HFONT,right,cols=10 text 25,18,"Qty",HFONT,right,cols=10 text 25,19,"Backordered",HFONT,right,cols=10 text 37,18,"Product",HFONT text 37,19,"Description",HFONT text 68,19,"UM",HFONT,center,cols=2 text 71,19,"Disc%",HFONT,right,cols=5 text 77,19,"Unit Price",HFONT,right,cols=9 text 87,19,"Extension",HFONT,right,cols=10 cfont 13,20,22,57,DFONT,right,cols=10 cfont 37,20,66,57,DFONT cfont 87,20,96,57,DFONT,right,cols=10 # message area and totals cerase 59,52,MAXCOLS,60 cbox 59,57,80.5,66,1,SHADE cbox 80.5,57,MAXCOLS,66 cbox 59,59,MAXCOLS,59 cbox 59,60.5,MAXCOLS,60.5 cbox 59,61.5,MAXCOLS,61.5 cbox 59,62.5,MAXCOLS,62.5 cbox 59,63.5,MAXCOLS,63.5 text 60,58,"Subtotal",HFONT text 83,58,{subtotal$},DFONT,right,cols=14 text 60,60,{dischd$},HFONT text 83,60,{discamt$},DFONT,right,cols=14 text 60,61,{taxhd$},HFONT text 83,61,{taxamt$},DFONT,right,cols=14 text 60,62,{mischd$},HFONT text 83,62,{miscamt$},DFONT,right,cols=14 text 60,63,{shiphd$},HFONT text 83,63,{shipamt$},DFONT,right,cols=14 text 60,65,"TOTAL",univers,12,bold text 84,65,{total$},univers,12,bold,right,cols=13 [OE Pick Slip] detect 80,4,"~../../.." detect 68,4," " const MAXCOLS=95 const MAXRCOLS=94 cols MAXCOLS page 66 rows 66 pcopies 1 prepage { # Appgen inserts a blank line on some forms after first page, so shift up one line as needed trash$=trim(text$[4]) if trash$="" then \ for i=2 to 66; \ text$[i-1]=text$[i]; \ text$[i]=""; \ next i title$="Picking Ticket" dt$=trim(get(80,4,8)) cust$=trim(get(68,6,12)) pg$=trim(get(90,6,6)) } # Title area cbox 1,1,MAXCOLS,66 cbox 1,1,MAXCOLS,8.5 erase 1,1,MAXCOLS,6 text 1,2.25,{title$},univers,18,bold,right,cols=93 if driver pdf image 1,1,12,6,"COMP_PDFLOGO" endif if driver laser image 1,1,12,6,"COMP_PCLLOGO" endif text 1,2.25,"COMP_NAME",univers,15,bold,center,cols=MAXCOLS text 1,3.35,"COMP_ADDR1",univers,12,center,cols=MAXCOLS text 1,4.35,"COMP_ADDR2",univers,12,center,cols=MAXCOLS text 1,5.35,"COMP_PHONES",univers,12,center,cols=MAXCOLS # Invoice block const HFONT=cgtimes,10,italic const DFONT=cgtimes,10,bold const SHADE=10 cbox 70,5.5,MAXCOLS,8.5 cbox 70,5.5,82,8.5,1,SHADE cbox 70,6.5,MAXCOLS,6.5 cbox 70,7.5,MAXCOLS,7.5 text 71,6,"Date",HFONT text 71,7,"Page No.",HFONT text 71,8,"Customer Code",HFONT text 83,6,{dt$},DFONT,bold text 83,7,{pg$},DFONT,bold text 83,8,{cust$},DFONT,bold # address sections cbox 1,8.5,MAXCOLS,13.5 cbox 1,8.5,10,13.5,1,SHADE cbox 52,8.5,61,13.5,1,SHADE text 2,9,"Bill To:",HFONT text 53,9,"Ship To:",HFONT cfont 11,9,45,13,DFONT cfont 62,9,96,13,DFONT # ribbon info cbox 1,15.5,MAXCOLS,16.5,1,SHADE cbox 1,16.5,MAXCOLS,17.5 cbox 11.5,15.5,11.5,17.5 cbox 21.5,15.5,21.5,17.5 cbox 38.5,15.5,38.5,17.5 cbox 42.5,15.5,42.5,17.5 cbox 59.5,15.5,59.5,17.5 cbox 69.5,15.5,69.5,17.5 cbox 74.5,15.5,74.5,17.5 text 2,16,"Order #",HFONT text 13,16,"Order Date",HFONT,center,cols=8 text 23,16,"Customer PO",HFONT text 40,16,"SM",HFONT text 44,16,"Payment Terms",HFONT text 61,16,"Ship Date",HFONT,center,cols=8 text 71,16,"Frt",HFONT text 76,16,"Shipped Via",HFONT cfont 1,17,10,17,DFONT cfont 13,17,20,17,DFONT,center,cols=8 cfont 23,17,37,17,DFONT cfont 40,17,41,17,DFONT cfont 44,17,58,17,DFONT cfont 61,17,68,17,DFONT,center,cols=8 cfont 71,17,73,17,DFONT cfont 76,17,95,17,DFONT # line detail cbox 1,17.5,70,19.5,1,SHADE cbox 70,17.5,MAXCOLS,19.5 cbox 1,19.5,MAXCOLS,66 cbox 11.5,17.5,11.5,66 cbox 23.5,17.5,23.5,66 cbox 35.5,17.5,35.5,66 cbox 67,17.5,67,66 cbox 70,19.5,MAXCOLS,66,1,SHADE cbox 76,17.5,76,19.5 cbox 86,17.5,86,19.5 text 1,18,"Qty",HFONT,right,cols=10 text 1,19,"Ordered",HFONT,right,cols=10 text 13,18,"Qty",HFONT,right,cols=10 text 13,19,"Shipped",HFONT,right,cols=10 text 25,18,"Qty",HFONT,right,cols=10 text 25,19,"Backordered",HFONT,right,cols=10 text 37,18,"Product",HFONT text 37,19,"Description",HFONT text 68,19,"UM",HFONT,center,cols=2 text 71,19,"Disc%",HFONT,right,cols=5 text 77,19,"Unit Price",HFONT,right,cols=9 text 86,19,"Extension",HFONT,right,cols=9 cfont 1,20,10,66,DFONT,right,cols=10 cfont 37,20,66,66,DFONT cfont 68,20,69,66,DFONT,center,cols=2 [OE Generic] # This rule set will set columns & rows and enhance the heading for other OE reports detect 1,1,"OE" detect 0,1,"Page" cols 132 rows 66 # copy 1 is generic 80 column, copy 2 is generic 132 column pcopies 2 prepage { maxlen=80 for i=1 to 66 if len(text$[i])>maxlen then maxlen=len(text$[i]) next i pgmname$=trim(get(1,1,10)) x=pos("Page"=text$[1]) compname$=trim(get(11,1,x-1-10)) pageno$=trim(get(x,1,11)) a=mask("","..:..:..") a=mask(text$[2]) title$=trim(get(1,2,a-1)) time$=trim(get(a,2,8)) rptdate$=trim(get(a+8,2,11)) } precopy { if maxlen>132 then skip=1 if copy=1 and maxlen>80 then skip=1 if copy=2 and maxlen=80 then skip=1 } # header const HFONT=univers,9,bold cerase 1,1,132,2 if copy 1 const MAXCOLS=80 const MAXRCOLS=79 cols MAXCOLS box .1,.1,80.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif if copy 2 const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif ################### # Generic reports # ################### [Generic] # This rule set will set columns & rows and enhance the heading for all other reports detect 0,1,"Page" cols 132 rows 66 # copy 1 is generic 80 column, copy 2 is generic 132 column pcopies 2 prepage { maxlen=80 for i=1 to 66 if len(text$[i])>maxlen then maxlen=len(text$[i]) next i pgmname$=trim(get(1,1,10)) x=pos("Page"=text$[1]) compname$=trim(get(11,1,x-1-10)) pageno$=trim(get(x,1,11)) a=mask("","..:..:..") a=mask(text$[2]) title$=trim(get(1,2,a-1)) time$=trim(get(a,2,8)) rptdate$=trim(get(a+8,2,11)) } precopy { if maxlen>132 then skip=1 if copy=1 and maxlen>80 then skip=1 if copy=2 and maxlen=80 then skip=1 } # header const HFONT=univers,9,bold cerase 1,1,132,2 if copy 1 const MAXCOLS=80 const MAXRCOLS=79 cols MAXCOLS box .1,.1,80.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif if copy 2 const MAXCOLS=132 const MAXRCOLS=131 cols MAXCOLS cbox .1,.1,132.9,2.5,3,20 text 2,1,{pgmname$},HFONT text 1,1.25,{compname$},univers,15,bold,center,cols=MAXCOLS text 1,2.5,{title$},univers,12,bold,center,cols=MAXCOLS text 1,1,{pageno$},HFONT,right,cols=MAXRCOLS text 1,2,{rptdate$},HFONT,right,cols=MAXRCOLS text 2,2,{time$},HFONT endif