# ################################################################## # osas7-7.rul rule file for standard OSAS7.0 Accounting Software # # Based upon OSAS 7.5 demo data # # Requires, at least, UnForm version 7.0 # ################################################################## # 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. # ######################################################### # # NOTE: SDSI has attempted to create # rule sets that are generic enough # that they cover as many options as # possible.If you find situations that # the rule set is not handling properly, # do not hesitate to contact us and # provide us with a sample text file # showing the problem. We will be # happy to provide the "correction" # in a timely manner. # The above assumes that no modifications # have been made to the application. # # Generic comments ###################################### # # Make changes to all constants as needed. # # Completed & Checked Forms: # ap - aged detail, aged summary # ap - checks: laser, blank, preprinted # ar - aged detail, aged summary # ar - statement: laser, plain paper, 8.5 x 11, std # dd - Dir Dep: laser, blank, preprinted # generic reports (row 1 contains either PAGE or Page) # gl - balance sheet: budget, prev yr # gl - income statement: budget, prev yr # gl - trial balance: actual, budget, prev yr # po - order: laser, plain, 8.5 x 11, std # pr - checks: laser, blank, preprinted # so - invoice: laser, plain paper, 8.5 x 11, std # so - pick list: laser, 8.5 x 11, plain paper, std # so - pack list: laser, 8.5 x 11, plain paper # # Modification history # # Last modified 02/25/2009 -- BCJ # 01/19/2009 - BCJ # added recd/bkord handling to P/O laser # 02/25/2009 - BCJ # added 3 direct deposit rule sets # Global constants ####################################### # Adjust the following constants to correct files and info # if you use the subst file then replace each constant # with subst info in rule sets below global COMP_NAME="Company Name: Edit rule file" global COMP_ADDR1="Address 1" global COMP_ADDR2="Address 2" global COMP_ADDR3="Address 3" global COMP_PHONES="###-###-#### Fax: ###-###-####" global COMP_EMAIL="E-Mail: xxxx@xxxxxxxxxxxxxxx.com" global COMP_WEBSITE="Website: www.xxxxxxxxxxxxxxx.com" # A/P check constants global AP_BANK_NAME="One Major Bank" global AP_BANK_ADDR1="1 Major Blvd" global AP_BANK_ADDR2="Major City CA 90123" global AP_ROUTING="12-345/6789" global AP_MICR_ACCOUNTNO=":123456789:9999-1234<34>" global AP_MICR="micr" # remove # to turn on global AP_NO_STUBS=2 # 1=vendor stub only # 2=vendor stub and payor stub # P/R check constants global PR_BANK_NAME="One Major Bank" global PR_BANK_ADDR1="1 Major Blvd" global PR_BANK_ADDR2="Major City CA 90123" global PR_ROUTING="12-345/6789" global PR_MICR_ACCOUNTNO=":123456789:9999-1234<34>" global PR_MICR="micr" # remove # to turn on global PR_NO_STUBS=2 # does not apply to long stub version # 1=employee stub only # 2=employee stub and employer stub # check signature on AP/PR checks, global SIGNATURE_IMAGE="#image" global SIGNATURE="" # insert signature file name # Logos global LOGO_IMAGE="image" global COMP_LOGO="sdsilogo.pcl" # change to your logo file name # watermarks global WATERMARK_SHADE=10 # adjust to desired darkness global WATERMARK="text" # change #gs on to gs on to turn on graphical shading # change gs on to #gs on to turn off graphical shading global GSON="gs on" # date mask for detects - 10/17/2001 global DATEMASK="[0-1][0-9]/[0-3][0-9]/[0-9][0-9]" # US dt #global DATEMASK="[0-3][0-9]/[0-1][0-9]/[0-9][0-9]" # Can dt # main heading constants global HFONT= univers,11,fit global HLFONT= HFONT,left global HCFONT= HFONT,center global HRFONT= HFONT,right global HSHADE= 30 # bold global HBFONT= HFONT,bold global HBLFONT=HBFONT,left global HBCFONT=HBFONT,center global HBRFONT=HBFONT,right # internal heading font constants (ribbons, detail headers) global IFONT= univers,10,italic,fit global ILFONT= IFONT,left global ICFONT= IFONT,center global IRFONT= IFONT,right global ISHADE= 20 # bold global IBFONT= IFONT,bold global IBLFONT=IBFONT,left global IBCFONT=IBFONT,center global IBRFONT=IBFONT,right # detail data font constants global DFONT= cgtimes,9 global DLFONT= DFONT,left global DCFONT= DFONT,center global DRFONT= DFONT,right global DSHADE= 10 # bold global DBFONT= DFONT,bold global DBLFONT=DBFONT,left global DBCFONT=DBFONT,center global DBRFONT=DBFONT,right # default major section box size global MBOXSIZE=5 [AP_AgedDetail] detect 0,2,"Accounts Payable Detail Aged Trial Balance" # set up document constants local MAXCOLS=133 # max cols to output local MAXRCOLS=132 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=60 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local MAX_COPIES=1 pcopies MAX_COPIES landscape dpi 600 # see global constant above GSON # graphical shading title "Vendor Aged Detail" # view in pdf properties prejob { brow=6 # used by rpt hdr } prepage { merge "zMrg load rpt header" } cmove LEFTCOL,1,MAXCOLS,MAXROWS,2,1 # default detail line local BROW=1 local EROW=MAXROWS cfont 2,BROW,10,EROW,DFONT # inv # cfont 12,BROW,14,EROW,DCFONT # st cfont 16,BROW,25,EROW,DCFONT # date cfont 27,BROW,42,EROW,DBRFONT # amount cfont 44,BROW,57,EROW,DRFONT # current cfont 59,BROW,72,EROW,DRFONT # 31-60 cfont 75,BROW,87,EROW,DRFONT # 61-90 cfont 90,BROW,102,EROW,DRFONT # 91-120 cfont 105,BROW,117,EROW,DRFONT # over 120 cfont 120,BROW,MAXRCOLS,EROW,DRFONT # future # header merge "zMrg Report Header 2" # detail cmove LEFTCOL,7,MAXCOLS,7,LEFTCOL,8 cbox LEFTCOL,7.25,RIGHTCOL,8.5,MBOXSIZE,10 local BROW=8 local EROW=8 cfont 2,BROW,10,EROW,IFONT # inv # cfont 12,BROW,14,EROW,ICFONT # st cfont 16,BROW,25,EROW,ICFONT # date cfont 30,BROW,42,EROW,IRFONT # amount cfont 45,BROW,57,EROW,IRFONT # current cfont 60,BROW,72,EROW,IRFONT # 31-60 cfont 75,BROW,87,EROW,IRFONT # 61-90 cfont 90,BROW,102,EROW,IRFONT # 91-120 cfont 105,BROW,117,EROW,IRFONT # over 120 cfont 120,BROW,MAXRCOLS,EROW,IRFONT # future # vendor heading font "~[A-Za-z0-9]@2,9,2,MAXROWS",0,0,37,1,DBFONT font "~[A-Za-z0-9]@2,9,2,MAXROWS",39,0,14,1,DBFONT font "~[A-Za-z0-9]@2,9,2,MAXROWS",60,0,67,1,DFONT # vendor total line erase "~VENDOR .* TOTAL@2,9,21,MAXROWS",0,-1,MAXCOLS,1 box "~VENDOR .* TOTAL@2,9,21,MAXROWS",28,-1,102,1,5 font "~VENDOR .* TOTAL@2,9,21,MAXROWS",0,0,20,1,DBFONT # invoice total font " TOTAL @11,9,17,MAXROWS",0,0,7,1,DFONT # Grand totals line erase "GRAND TOTAL",0,-1,MAXCOLS,1 box "GRAND TOTAL",-2,-1,{MAXCOLS-1},2,1,10 font "GRAND TOTAL",-1,0,20,1,IBLFONT font "End of Report",0,0,14,1,DFONT [AP_AgedSummary] detect 0,2,"Accounts Payable Summary Aged Trial Balance" # set up document constants local MAXCOLS=133 # max cols to output local MAXRCOLS=132 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=60 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local MAX_COPIES=1 pcopies MAX_COPIES landscape dpi 600 # see global constant above GSON # graphical shading title "Vendor Aged Summary" # view in pdf properties prejob { brow=6 # used by rpt hdr } prepage { merge "zMrg load rpt header" } cmove LEFTCOL,1,MAXCOLS,MAXROWS,2,1 # default detail line local BROW=1 local EROW=MAXROWS cfont 2,BROW,7,EROW,DFONT # vendor cfont 9,BROW,28,EROW,DCFONT # name cfont 30,BROW,42,EROW,DBRFONT # amount cfont 45,BROW,57,EROW,DRFONT # current cfont 60,BROW,72,EROW,DRFONT # 31-60 cfont 75,BROW,87,EROW,DRFONT # 61-90 cfont 90,BROW,102,EROW,DRFONT # 91-120 cfont 105,BROW,117,EROW,DRFONT # over 120 cfont 120,BROW,MAXRCOLS,EROW,DRFONT # future # header merge "zMrg Report Header 2" # detail cmove LEFTCOL,7,MAXCOLS,7,LEFTCOL,8 cbox LEFTCOL,7.25,RIGHTCOL,8.5,MBOXSIZE,10 local BROW=8 local EROW=8 cfont 2,BROW,8,EROW,IFONT # vendor cfont 10,BROW,28,EROW,ICFONT # name cfont 30,BROW,42,EROW,IRFONT # amount cfont 45,BROW,57,EROW,IRFONT # current cfont 60,BROW,72,EROW,IRFONT # 31-60 cfont 75,BROW,87,EROW,IRFONT # 61-90 cfont 90,BROW,102,EROW,IRFONT # 91-120 cfont 105,BROW,117,EROW,IRFONT # over 120 cfont 120,BROW,MAXRCOLS,EROW,IRFONT # future # vendor heading font "~[A-Za-z0-9]@2,9,2,MAXROWS",0,0,37,1,DBFONT font "~[A-Za-z0-9]@2,9,2,MAXROWS",39,0,14,1,DBFONT font "~[A-Za-z0-9]@2,9,2,MAXROWS",60,0,67,1,DFONT # vendor total line font "~VENDOR .* TOTAL@3,9,21,MAXROWS",0,0,20,1,DFONT # Grand totals line erase "GRAND TOTAL",0,-1,MAXCOLS,1 box "GRAND TOTAL",-2,-1,MAXRCOLS,2,1,10 font "GRAND TOTAL",-1,0,20,1,IBLFONT font "End of Report",0,0,14,1,DFONT [AP_CheckBlank] # Assumes company name heading printed on stub detect 54,8,"~[0-9][0-9][0-9][0-9][0-9][0-9][0-9]" detect 43,8,"~DATEMASK.." detect 0,22,"Vendor No." # set up document constants local MAXCOLS=82 local MAXRCOLS=81 local MAXROWS=62 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line cols MAXCOLS rows MAXROWS page 42 local MAX_COPIES=1 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Vendor Check - Blank" # view in pdf properties prepage { brow=22,erow=40 begin_copy_loop: text$[brow+21]=text$[brow] brow=brow+1 if brow=erow then : goto end_copy_loop else goto begin_copy_loop endif end_copy_loop: } # make space on left cmove 1,1,MAXCOLS,MAXROWS,2,1 # Check LOGO_IMAGE 1,1,10,5,"COMP_LOGO" cbox LEFTCOL,1,RIGHTCOL,17.75,MBOXSIZE text 15,2.25,"COMP_NAME",HBFONT,14 text 15,3.35,"COMP_ADDR1",HFONT,12 text 15,4.35,"COMP_ADDR2",HFONT,12 text 15,5.35,"COMP_ADDR3",HFONT,12 text 49,2.25,"AP_BANK_NAME",DBFONT text 49,3.05,"AP_BANK_ADDR1",DFONT text 49,3.85,"AP_BANK_ADDR2",DFONT text 70,3.35,"AP_ROUTING",DBFONT # rtg # cmove 44,8,MAXCOLS,8,44,7 cbox 43,5.5,RIGHTCOL,7.5,1,crows=6.5::100,ccols=54 62 text 44,6,"Date",ICFONT,10,cols=10,shade=0 cfont 44,7,53,7,DBCFONT,11 text 55,6,"Check #",ICFONT,10,cols=7,shade=0 cfont 55,7,61,7,DBCFONT,11 text 63,6,"Amount",IRFONT,10,cols=18,shade=0 cfont 63,7,81,7,DBRFONT,11 text 2,10,"Pay",IFONT,14 text 7,10,{trim(cut(2,9,80,""))},DBFONT,italic,11,fit text 2,13,"Pay",IFONT text 2,14,"to the",IFONT text 2,15,"Order",IFONT text 2,16,"of",IFONT cmove 7,12,47,15,7,13 cfont 8,13,51,16,DBFONT,11 SIGNATURE_IMAGE 50,15,0,0,"SIGNATURE" box 50,16.25,30,1,3 text 50,14.5,"Check Void After 180 Days",ICFONT,cols=30 text 50,17,"Authorized Signature",ICFONT,cols=30 AP_MICR 15,18.5,"AP_MICR_ACCOUNTNO",{trim(get(43,7,7))} #move stubs up one line cmove LEFTCOL,22,MAXCOLS,MAXROWS,LEFTCOL,21 # Top stub - vendor's cerase 1,20,MAXCOLS,20 cbox LEFTCOL,20.25,RIGHTCOL,20.25 text 2,21,"COMP_NAME",HBFONT cbox 25,20.5,76,23,1,crows=21.35::DSHADE,ccols=36 68 cfont 26,21,35,21,ICFONT cfont 37,21,67,21,ICFONT cfont 69,21,75,21,ICFONT cfont 26,22,35,22,DBCFONT cfont 37,22,67,22,DBCFONT cfont 69,22,75,22,DBCFONT cbox LEFTCOL,23,RIGHTCOL,36.5,MBOXSIZE,crows=24.5::DSHADE, ccols=13 25 37 51 66 cfont 2,24,12,24,ICFONT cfont 14,24,24,24,ICFONT cfont 26,24,36,24,ICFONT cfont 38,24,50,24,IRFONT cfont 52,24,65,24,IRFONT cfont 67,24,MAXRCOLS,24,IRFONT cfont 2,25,12,36,DBCFONT cfont 14,25,24,36,DBCFONT cfont 26,25,36,36,DBCFONT cfont 38,25,50,36,DBRFONT cfont 52,25,65,36,DBRFONT cfont 67,25,MAXRCOLS,36,DBRFONT cbox LEFTCOL,36.5,RIGHTCOL,39,MBOXSIZE,crows=37.5::100, ccols=13 37 51 66 cfont 2,37,12,37,ICFONT,shade=0 cfont 14,37,36,37,ICFONT,shade=0 cfont 38,37,50,37,IRFONT,shade=0 cfont 52,37,65,37,IRFONT,shade=0 cfont 67,37,MAXRCOLS,37,IRFONT,shade=0 cfont 2,38,12,38,DBCFONT cfont 14,38,36,38,DBCFONT cfont 38,38,50,38,DBRFONT cfont 52,38,65,38,DBRFONT cfont 67,38,MAXRCOLS,38,DBRFONT text 1,40,"Vendor's Copy",DBRFONT,cols=MAXRCOLS # bottom stub - Payor's cerase 1,41,MAXCOLS,41 cbox LEFTCOL,41,MAXCOLS,41 text 2,42,"COMP_NAME",HBFONT cbox 25,41.5,76,44,1,crows=42.5::DSHADE,ccols=36 68 cfont 26,42,35,42,ICFONT cfont 37,42,67,42,ICFONT cfont 69,42,75,42,ICFONT cfont 26,43,35,43,DBCFONT cfont 37,43,67,43,DBCFONT cfont 69,43,75,43,DBCFONT cbox LEFTCOL,44,MAXCOLS,57.5,MBOXSIZE,crows=45.5::DSHADE,ccols=13 25 37 51 66 cfont 2,45,12,45,ICFONT cfont 14,45,24,45,ICFONT cfont 26,45,36,45,ICFONT cfont 38,45,50,45,IRFONT cfont 52,45,65,45,IRFONT cfont 67,45,MAXRCOLS,45,IRFONT cfont 2,46,12,57,DBCFONT cfont 14,46,24,57,DBCFONT cfont 26,46,36,57,DBCFONT cfont 38,46,50,57,DBRFONT cfont 52,46,65,57,DBRFONT cfont 67,46,MAXRCOLS,57,DBRFONT cbox LEFTCOL,57.5,MAXCOLS,60,MBOXSIZE,crows=58.5::100,ccols=13 37 51 66 cfont 2,58,12,58,ICFONT,shade=0 cfont 14,58,36,58,ICFONT,shade=0 cfont 38,58,50,58,IRFONT,shade=0 cfont 52,58,65,58,IRFONT,shade=0 cfont 67,58,MAXRCOLS,58,IRFONT,shade=0 cfont 2,59,12,59,DBCFONT cfont 14,59,36,59,DBCFONT cfont 38,59,50,59,DBRFONT cfont 52,59,65,59,DBRFONT cfont 67,59,MAXRCOLS,59,DBRFONT text 1,61,"Payor's Copy",DBRFONT,cols=MAXRCOLS [AP_CheckLaser] # Assumes company name heading printed on stub detect 43,8,"~[0-9][0-9][0-9][0-9][0-9][0-9][0-9]" detect 51,8,"~DATEMASK.." detect 0,21,"Vendor No." # set up document constants local MAXCOLS=82 local MAXRCOLS=81 local MAXROWS=62 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line cols MAXCOLS rows MAXROWS local MAX_COPIES=1 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Vendor Check - laser" # view in pdf properties # make space on left cmove 1,1,MAXCOLS,MAXROWS,2,1 # Check LOGO_IMAGE 1,1,10,5,"COMP_LOGO" cbox LEFTCOL,1,RIGHTCOL,17.75,MBOXSIZE text 15,2.25,"COMP_NAME",HBFONT,14 text 15,3.35,"COMP_ADDR1",HFONT,12 text 15,4.35,"COMP_ADDR2",HFONT,12 text 15,5.35,"COMP_ADDR3",HFONT,12 text 49,2.25,"AP_BANK_NAME",DBFONT text 49,3.05,"AP_BANK_ADDR1",DFONT text 49,3.85,"AP_BANK_ADDR2",DFONT text 70,3.35,"AP_ROUTING",DBFONT # rtg # cmove 44,8,MAXCOLS,8,44,7 cbox 43,5.5,RIGHTCOL,7.5,1,crows=6.5::100,ccols=51 62 text 44,6,"Check #",ICFONT,10,cols=7,shade=0 cfont 44,7,50,7,DBCFONT,11 text 52,6,"Date",ICFONT,10,cols=10,shade=0 cfont 52,7,61,7,DBCFONT,11 text 63,6,"Amount",IRFONT,10,cols=18,shade=0 cfont 63,7,81,7,DBRFONT,11 text 2,10,"Pay",IFONT,14 text 7,10,{trim(cut(5,9,80,""))},DBFONT,italic,11,fit text 2,13,"Pay",IFONT text 2,14,"to the",IFONT text 2,15,"Order",IFONT text 2,16,"of",IFONT cmove 7,11,47,14,7,13 cfont 8,13,51,16,DBFONT,11 SIGNATURE_IMAGE 50,15,0,0,"SIGNATURE" box 50,16.25,30,1,3 text 50,14.5,"Check Void After 180 Days",ICFONT,cols=30 text 50,17,"Authorized Signature",ICFONT,cols=30 AP_MICR 15,18.5,"AP_MICR_ACCOUNTNO",{trim(get(43,7,7))} # Top stub - vendor's cerase 1,20,MAXCOLS,20 cbox LEFTCOL,20.25,RIGHTCOL,20.25 text 2,21,"COMP_NAME",HBFONT cbox 25,20.5,76,23,1,crows=21.35::DSHADE,ccols=36 68 cfont 26,21,35,21,ICFONT cfont 37,21,67,21,ICFONT cfont 69,21,75,21,ICFONT cfont 26,22,35,22,DBCFONT cfont 37,22,67,22,DBCFONT cfont 69,22,75,22,DBCFONT cbox LEFTCOL,23,RIGHTCOL,36.5,MBOXSIZE,crows=24.5::DSHADE, ccols=13 25 37 51 66 cfont 2,24,12,24,ICFONT cfont 14,24,24,24,ICFONT cfont 26,24,36,24,ICFONT cfont 38,24,50,24,IRFONT cfont 52,24,65,24,IRFONT cfont 67,24,MAXRCOLS,24,IRFONT cfont 2,25,12,36,DBCFONT cfont 14,25,24,36,DBCFONT cfont 26,25,36,36,DBCFONT cfont 38,25,50,36,DBRFONT cfont 52,25,65,36,DBRFONT cfont 67,25,MAXRCOLS,36,DBRFONT cbox LEFTCOL,36.5,RIGHTCOL,39,MBOXSIZE,crows=37.5::100, ccols=13 37 51 66 cfont 2,37,12,37,ICFONT,shade=0 cfont 14,37,36,37,ICFONT,shade=0 cfont 38,37,50,37,IRFONT,shade=0 cfont 52,37,65,37,IRFONT,shade=0 cfont 67,37,MAXRCOLS,37,IRFONT,shade=0 cfont 2,38,12,38,DBCFONT cfont 14,38,36,38,DBCFONT cfont 38,38,50,38,DBRFONT cfont 52,38,65,38,DBRFONT cfont 67,38,MAXRCOLS,38,DBRFONT text 1,40,"Vendor's Copy",DBRFONT,cols=MAXRCOLS # bottom stub - Payor's cerase 1,41,MAXCOLS,41 cbox LEFTCOL,41,MAXCOLS,41 text 2,42,"COMP_NAME",HBFONT cbox 25,41.5,76,44,1,crows=42.5::DSHADE,ccols=36 68 cfont 26,42,35,42,ICFONT cfont 37,42,67,42,ICFONT cfont 69,42,75,42,ICFONT cfont 26,43,35,43,DBCFONT cfont 37,43,67,43,DBCFONT cfont 69,43,75,43,DBCFONT cbox LEFTCOL,44,MAXCOLS,57.5,MBOXSIZE,crows=45.5::DSHADE,ccols=13 25 37 51 66 cfont 2,45,12,45,ICFONT cfont 14,45,24,45,ICFONT cfont 26,45,36,45,ICFONT cfont 38,45,50,45,IRFONT cfont 52,45,65,45,IRFONT cfont 67,45,MAXRCOLS,45,IRFONT cfont 2,46,12,57,DBCFONT cfont 14,46,24,57,DBCFONT cfont 26,46,36,57,DBCFONT cfont 38,46,50,57,DBRFONT cfont 52,46,65,57,DBRFONT cfont 67,46,MAXRCOLS,57,DBRFONT cbox LEFTCOL,57.5,MAXCOLS,60,MBOXSIZE,crows=58.5::100,ccols=13 37 51 66 cfont 2,58,12,58,ICFONT,shade=0 cfont 14,58,36,58,ICFONT,shade=0 cfont 38,58,50,58,IRFONT,shade=0 cfont 52,58,65,58,IRFONT,shade=0 cfont 67,58,MAXRCOLS,58,IRFONT,shade=0 cfont 2,59,12,59,DBCFONT cfont 14,59,36,59,DBCFONT cfont 38,59,50,59,DBRFONT cfont 52,59,65,59,DBRFONT cfont 67,59,MAXRCOLS,59,DBRFONT text 1,61,"Payor's Copy",DBRFONT,cols=MAXRCOLS [AP_CheckPreprinted] # Assumes company name heading printed on stub detect 54,8,"~[0-9][0-9][0-9][0-9][0-9][0-9][0-9]" detect 43,8,"~DATEMASK.." detect 33,23,"~ [A-Za-z0-9]+ " # set up document constants local MAXCOLS=82 local MAXRCOLS=81 local MAXROWS=62 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line cols MAXCOLS rows MAXROWS page 42 local MAX_COPIES=1 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Vendor Check - Preprinted" # view in pdf properties prepage { brow=22,erow=40 begin_copy_loop: text$[brow+21]=text$[brow] brow=brow+1 if brow=erow then : goto end_copy_loop else goto begin_copy_loop endif end_copy_loop: } # make space on left cmove 1,1,MAXCOLS,MAXROWS,2,1 # Check LOGO_IMAGE 1,1,10,5,"COMP_LOGO" cbox LEFTCOL,1,RIGHTCOL,17.75,MBOXSIZE text 15,2.25,"COMP_NAME",HBFONT,14 text 15,3.35,"COMP_ADDR1",HFONT,12 text 15,4.35,"COMP_ADDR2",HFONT,12 text 15,5.35,"COMP_ADDR3",HFONT,12 text 49,2.25,"AP_BANK_NAME",DBFONT text 49,3.05,"AP_BANK_ADDR1",DFONT text 49,3.85,"AP_BANK_ADDR2",DFONT text 70,3.35,"AP_ROUTING",DBFONT # rtg # cmove 44,8,MAXCOLS,8,44,7 cbox 43,5.5,RIGHTCOL,7.5,1,crows=6.5::100,ccols=54 62 text 44,6,"Date",ICFONT,10,cols=10,shade=0 cfont 44,7,53,7,DBCFONT,11 text 55,6,"Check #",ICFONT,10,cols=7,shade=0 cfont 55,7,61,7,DBCFONT,11 text 63,6,"Amount",IRFONT,10,cols=18,shade=0 cfont 63,7,81,7,DBRFONT,11 text 2,10,"Pay",IFONT,14 text 7,10,{trim(cut(2,9,80,""))},DBFONT,italic,11,fit text 2,13,"Pay",IFONT text 2,14,"to the",IFONT text 2,15,"Order",IFONT text 2,16,"of",IFONT cmove 7,12,47,15,7,13 cfont 8,13,51,16,DBFONT,11 SIGNATURE_IMAGE 50,15,0,0,"SIGNATURE" box 50,16.25,30,1,3 text 50,14.5,"Check Void After 180 Days",ICFONT,cols=30 text 50,17,"Authorized Signature",ICFONT,cols=30 AP_MICR 15,18.5,"AP_MICR_ACCOUNTNO",{trim(get(43,7,7))} #move stubs up one line cmove LEFTCOL,22,MAXCOLS,MAXROWS,1,21 # Top stub - vendor's cerase 1,20,MAXCOLS,20 cbox LEFTCOL,20.25,RIGHTCOL,20.25 text 2,21,"COMP_NAME",HBFONT cbox 34,20.5,76,23,1,crows=21.35::DSHADE,ccols=44 text 34,21,"Vendor No.",ICFONT,cols=10 text 45,21,"Vendor Name",ICFONT,cols=32 cfont 34,22,43,22,DBCFONT cfont 45,22,76,22,DBCFONT cbox LEFTCOL,23,RIGHTCOL,36.5,MBOXSIZE,crows=24.5::DSHADE, ccols=12 24 40 58 text 2,24,"Trans. Date",ICFONT,cols=10 text 13,24,"Reference",ICFONT,cols=11 text 25,24,"Gross Amount",IRFONT,cols=15 text 41,24,"Deduction",IRFONT,cols=17 text 59,24,"Net Amount",IRFONT,cols=23 cfont 2,25,11,36,DBCFONT cfont 13,25,23,36,DBCFONT cfont 25,25,39,36,DBRFONT cfont 41,25,57,36,DBRFONT cfont 59,25,MAXRCOLS,36,DBRFONT cbox LEFTCOL,36.5,RIGHTCOL,39,MBOXSIZE,crows=37.5::100, ccols=12 24 40 58 text 2,37,"Check Date",ICFONT,cols=10,shade=0 text 13,37,"Check No.",ICFONT,cols=11,shade=0 text 25,37,"Total Gross",IRFONT,cols=15,shade=0 text 41,37,"Total Ded.",IRFONT,cols=17,shade=0 text 59,37,"Check Amount",IRFONT,cols=23,shade=0 cfont 2,38,11,38,DBCFONT cfont 13,38,23,38,DBCFONT cfont 25,38,39,38,DBRFONT cfont 41,38,57,38,DBRFONT cfont 59,38,MAXRCOLS,38,DBRFONT text 1,40,"Vendor's Copy",DBRFONT,cols=MAXRCOLS # bottom stub - Payor's cerase 1,41,MAXCOLS,41 cbox LEFTCOL,41,MAXCOLS,41 text 2,42,"COMP_NAME",HBFONT cbox 34,41.5,76,44,1,crows=42.5::DSHADE,ccols=44 text 34,42,"Vendor No.",ICFONT,cols=10 text 45,42,"Vendor Name",ICFONT,cols=32 cfont 34,43,43,43,DBCFONT cfont 45,43,76,43,DBCFONT cbox LEFTCOL,44,RIGHTCOL,57.5,MBOXSIZE,crows=45.5::DSHADE,ccols=12 24 40 58 text 2,45,"Trans. Date",ICFONT,cols=10 text 13,45,"Reference",ICFONT,cols=11 text 25,45,"Gross Amount",IRFONT,cols=15 text 41,45,"Deduction",IRFONT,cols=17 text 59,45,"Net Amount",IRFONT,cols=23 cfont 2,46,11,57,DBCFONT cfont 13,46,23,57,DBCFONT cfont 25,46,39,57,DBRFONT cfont 41,46,57,57,DBRFONT cfont 59,46,MAXRCOLS,57,DBRFONT cbox LEFTCOL,57.5,RIGHTCOL,60,MBOXSIZE,crows=58.5::100,ccols=12 24 40 58 text 2,58,"Check Date",ICFONT,cols=10,shade=0 text 13,58,"Check No.",ICFONT,cols=11,shade=0 text 25,58,"Total Gross",IRFONT,cols=15,shade=0 text 41,58,"Total Ded.",IRFONT,cols=17,shade=0 text 59,58,"Check Amount",IRFONT,cols=23,shade=0 cfont 2,59,11,59,DBCFONT cfont 13,59,23,59,DBCFONT cfont 25,59,39,59,DBRFONT cfont 41,59,57,59,DBRFONT cfont 59,59,MAXRCOLS,59,DBRFONT text 1,61,"Payor's Copy",DBRFONT,cols=MAXRCOLS [AR_AgedDetail] detect 0,2,"Detail Accounts Receivable Aged Trial Balance" # set up document constants local MAXCOLS=133 # max cols to output local MAXRCOLS=132 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=60 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local MAX_COPIES=1 pcopies MAX_COPIES landscape dpi 600 # see global constant above GSON # graphical shading title "Customer Aged Detail" # view in pdf properties prejob { brow=3 # used by rpt hdr } prepage { merge "zMrg load rpt header" } cmove LEFTCOL,1,MAXCOLS,MAXROWS,2,1 # default detail line local BROW=1 local EROW=MAXROWS cfont 2,BROW,9,EROW,DFONT # inv # cfont 11,BROW,11,EROW,DCFONT # st cfont 13,BROW,13,EROW,DCFONT # tp cfont 15,BROW,23,EROW,DCFONT # date cfont 25,BROW,36,EROW,DBRFONT # amount cfont 39,BROW,52,EROW,DRFONT # current cfont 55,BROW,68,EROW,DRFONT # 31-60 cfont 71,BROW,84,EROW,DRFONT # 61-90 cfont 87,BROW,100,EROW,DRFONT # 91-120 cfont 103,BROW,116,EROW,DRFONT # over 120 cfont 119,BROW,MAXRCOLS,EROW,DRFONT # unapplied # header merge "zMrg Report Header" # detail cerase 1,7,MAXCOLS,7 cbox LEFTCOL,4.25,RIGHTCOL,6.5,MBOXSIZE,10 local BROW=5 local EROW=6 cfont 2,BROW,9,EROW,IFONT # inv # cfont 11,BROW,11,EROW,ICFONT # st cfont 13,BROW,13,EROW,ICFONT # tp cfont 15,BROW,23,EROW,ICFONT # date cfont 25,BROW,36,EROW,IRFONT # amount cfont 39,BROW,52,EROW,IRFONT # current cfont 55,BROW,68,EROW,IRFONT # 31-60 cfont 71,BROW,84,EROW,IRFONT # 61-90 cfont 87,BROW,100,EROW,IRFONT # 91-120 cfont 103,BROW,116,EROW,IRFONT # over 120 cfont 119,BROW,MAXRCOLS,EROW,IRFONT # unapplied # customer heading font "~(...)...-@40,8,48,MAXROWS",-40,0,37,1,DBFONT font "~(...)...-@40,8,48,MAXROWS",-2,0,48,1,DBCFONT font "~(...)...-@40,8,48,MAXROWS",50,0,40,1,DRFONT # customer total line erase "~Cust .* TOTAL@1,9,20,MAXROWS",0,-1,MAXCOLS,1 box "~Cust .* TOTAL@1,9,20,MAXROWS",21,-1,110,1,5 font "~Cust .* TOTAL@1,9,20,MAXROWS",0,0,20,1,DBFONT # Grand totals line erase "GRAND TOTAL",0,-1,MAXCOLS,1 box "GRAND TOTAL",-1,-1,MAXRCOLS,2,1,10 font "GRAND TOTAL",0,0,20,1,IBFONT #font "GRAND TOTAL",15,0,MAXCOLS,1,DBFONT font "End of Report",0,0,14,1,DFONT [AR_AgedSummary] detect 0,2,"Summary Accounts Receivable Aged Trial Balance" # set up document constants local MAXCOLS=133 # max cols to output local MAXRCOLS=132 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=60 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local MAX_COPIES=1 pcopies MAX_COPIES landscape dpi 600 # see global constant above GSON # graphical shading title "Customer Aged Summary" # view in pdf properties prejob { brow=3 # used by rpt hdr } prepage { merge "zMrg load rpt header" } cmove LEFTCOL,1,RIGHTCOL,MAXROWS,2,1 # default detail line local BROW=1 local EROW=MAXROWS cfont 2,BROW,9,EROW,DFONT # cust id cfont 11,BROW,23,EROW,DBCFONT # phone cfont 25,BROW,28,EROW,DCFONT # sls rep cfont 30,BROW,33,EROW,DCFONT # dist cfont 35,BROW,48,EROW,DBRFONT # amount cfont 51,BROW,62,EROW,DRFONT # current cfont 65,BROW,76,EROW,DRFONT # 31-60 cfont 79,BROW,90,EROW,DRFONT # 61-90 cfont 93,BROW,104,EROW,DRFONT # 91-120 cfont 107,BROW,118,EROW,DRFONT # over 120 cfont 121,BROW,MAXRCOLS,EROW,DRFONT # unapplied # header merge "zMrg Report Header" # detail cerase 1,7,MAXCOLS,7 cbox LEFTCOL,4.25,RIGHTCOL,6.5,1,10 local BROW=5 local EROW=6 cfont 2,BROW,9,EROW,IFONT # cust id cfont 11,BROW,23,EROW,ICFONT # phone cfont 25,BROW,28,EROW,ICFONT # sls rep cfont 30,BROW,33,EROW,ICFONT # dist cfont 35,BROW,48,EROW,IRFONT # amount cfont 51,BROW,62,EROW,IRFONT # current cfont 65,BROW,76,EROW,IRFONT # 31-60 cfont 79,BROW,90,EROW,IRFONT # 61-90 cfont 93,BROW,104,EROW,IRFONT # 91-120 cfont 107,BROW,118,EROW,IRFONT # over 120 cfont 121,BROW,MAXRCOLS,EROW,IRFONT # unapplied # customer heading font "~[(][0-9 ][0-9 ][0-9 ][)][0-9 ][0-9 ][0-9 ]-@11,8,19,MAXROWS",-9,1,37,2,DBFONT # Grand totals line erase "GRAND TOTAL",0,-1,MAXCOLS,1 box "GRAND TOTAL",-1,-1,MAXRCOLS,2,1,10 font "GRAND TOTAL",0,0,20,1,IBFONT #font "GRAND TOTAL",15,0,MAXCOLS,1,DBFONT font "End of Report",0,0,14,1,DFONT [AR_Statement8.5x11] detect 49,7,"~ DATEMASK" detect 77,13,"~\.[0-9][0-9]" # set up document constants local MAXCOLS=80 # max cols to output local MAXRCOLS=79 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local CUSTOMER_COPY=1 local REMITTANCE_COPY=2 local FILE_COPY=3 local MAX_COPIES=3 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Statement - 8.5x11" # view in pdf properties prejob { logocols=14,logorows=6 doc_title$="STATEMENT" merge "zMrg get watermark text" # set up copy titles dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then copy_title$[CUSTOMER_COPY]="Customer Copy" if MAX_COPIES>=2 then copy_title$[REMITTANCE_COPY]="Remittance Copy" if MAX_COPIES>=3 then copy_title$[FILE_COPY]="File Copy" } prepage { page=page+1 if page>1 then : for i=2 to MAXROWS text$[i-1]=text$[i] text$[i]="" next i endif date$=trim(get(50,7,10)) cust_code$=trim(get(61,7,7)) pageno$=trim(get(69,7,4)) xcol=0,xrow=0 merge "zMrg get company info" # add zip barcode xrow=14;xcols=40 #merge "zmrg get zip" } # default detail line local BROW=21 local EROW=52 cfont 2,BROW,11,EROW,DBCFONT # date cfont 13,BROW,22,EROW,DFONT # inv # cfont 24,BROW,26,EROW,DCFONT # type cfont 28,BROW,39,EROW,DFONT # check # cfont 41,BROW,50,EROW,DBRFONT # charges cfont 52,BROW,63,EROW,DBRFONT # credits cfont 65,BROW,MAXRCOLS,EROW,DBRFONT # balance # header section cerase 1,1,MAXCOLS,7 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=9:MBOXSIZE merge "zMrg Form Header" # Invoice block cbox 60,4,RIGHTCOL,9,1,crows=5.5 7.25,ccols=70::ISHADE text 61,5,"Date",IFONT text 61,6.75,"Account",IFONT text 61,8.5,"Page",IFONT text 71,5,{date$},DBFONT,10 text 71,6.75,{cust_code$},DBFONT,10 text 71,8.5,{pageno$},DBFONT,10 # address & balance info cbox LEFTCOL,9,RIGHTCOL,19,MBOXSIZE cfont 1,10,49,18,DBFONT text 51,13,"Amount Due",IBFONT,10 cfont 70,13,MAXRCOLS,13,DBRFONT,10 text 51,15,"Terms",IBFONT,10 cfont 66,15,MAXRCOLS,15,DBRFONT,10 # zip bar #barcode 2,16,{shipzip$},900,12.0,2 # detail section cbox LEFTCOL,19,RIGHTCOL,51,MBOXSIZE,crows=20.5::DSHADE, ccols=12 23 27 40 51 64 text 2,20,"Invoice Date",ICFONT,cols=10 text 13,20,"Invoice No",IFONT text 24,20,"Type",ICFONT,cols=3 text 28,20,"Check No",IRFONT, cols=12 text 39,20,"Charges",IRFONT,cols=12 text 52,20,"Credits",IRFONT,cols=12 text 67,20,"Balance",IRFONT,cols=13 # Messages cbox LEFTCOL,51,MAXCOLS,58,MBOXSIZE cfont 2,52,MAXCOLS,57,IFONT # watermark - large font with light shading WATERMARK 1,50.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # footer text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS cbox LEFTCOL,58,RIGHTCOL,61,MBOXSIZE,crows=59.5::HSHADE 61, ccols=14 27 40 53 66 text 1,59,"Current",IRFONT,cols=13 text 15,59,"31-60 Days",IRFONT,cols=12 text 28,59,"61-90 Days",IRFONT,cols=12 text 41,59,"Over 90 Days",IRFONT,cols=12 text 54,59,"Finance Charge", IRFONT,cols=12 text 67,59,"Amount Due", IBRFONT,cols=12 cfont 1,60,13,60,DBRFONT cfont 15,60,26,60,DBRFONT cfont 28,60,39,60,DBRFONT cfont 41,60,52,60,DBRFONT,black cfont 54,60,65,60,DBRFONT,black cfont 67,60,MAXRCOLS,60,DBRFONT,10 [AR_StatementLaser] detect 61,6,"~ DATEMASK" detect 77,13,"~\.[0-9][0-9]" # set up document constants local MAXCOLS=81 # max cols to output local MAXRCOLS=80 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local CUSTOMER_COPY=1 local REMITTANCE_COPY=2 local FILE_COPY=3 local MAX_COPIES=3 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Statement - laser" # view in pdf properties prejob { doc_title$="STATEMENT" merge "zMrg get watermark text" logocols=12,logorows=6 dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then copy_title$[CUSTOMER_COPY]="Customer Copy" if MAX_COPIES>=2 then copy_title$[REMITTANCE_COPY]="Remittance Copy" if MAX_COPIES>=3 then copy_title$[FILE_COPY]="File Copy" } prepage { xcol=0,xrow=0 merge "zMrg get company info" } cmove LEFTCOL,1,RIGHTCOL,MAXROWS,2,1 # default detail line local BROW=21 local EROW=52 cfont 2,BROW,11,EROW,DBCFONT # date cfont 13,BROW,24,EROW,DFONT # inv # cfont 26,BROW,28,EROW,DCFONT # type cfont 30,BROW,41,EROW,DFONT # check # cfont 43,BROW,54,EROW,DBRFONT # charges cfont 56,BROW,67,EROW,DBRFONT # credits cfont 69,BROW,MAXRCOLS,EROW,DBRFONT # balance # header section cerase 1,1,MAXCOLS,7 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE merge "zMrg Form Header" # Invoice block cbox 60,4,RIGHTCOL,9,1,crows=5.5 7.25,ccols=70::ISHADE text 61,5,"Date",IFONT text 61,6.75,"Account",IFONT text 61,8.5,"Page",IFONT text 71,5,{trim(cut(62,6,10,""))},DBFONT,10 text 71,6.75,{trim(cut(62,7,10,""))},DBFONT,10 text 71,8.5,{trim(cut(62,5,10,""))},DBFONT,10 # address & balance info cfont 1,10,49,18,DBFONT text 51,13,"Amount Due",IBFONT,10 cfont 70,13,MAXRCOLS,13,DBRFONT,10 text 51,15,"Terms",IBFONT,10 cfont 66,15,MAXRCOLS,15,DBRFONT,10 # detail section cbox LEFTCOL,19,RIGHTCOL,53,MBOXSIZE,crows=20.5::DSHADE, ccols=12 25 29 42 55 68 text 2,20,"Invoice Date",ICFONT,cols=10 text 13,20,"Invoice No",IFONT text 26,20,"Type",ICFONT,cols=3 text 30,20,"Check No",IFONT text 43,20,"Charges",IRFONT,cols=12 text 56,20,"Credits",IRFONT,cols=12 text 68,20,"Balance",IRFONT,cols=13 # handle special PO # line font "PO Number ",-2,0,10,1,ICFONT font "PO Number ",9,0,50,1,ILFONT # Messages cbox LEFTCOL,53,RIGHTCOL,58,MBOXSIZE cfont 2,54,MAXCOLS,57,IFONT # watermark - large font with light shading WATERMARK 1,52.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # footer text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS cbox LEFTCOL,58,RIGHTCOL,61,MBOXSIZE,crows=59.5 61::HSHADE, ccols=14 27 40 53 66 text 1,60.5,"Current",IRFONT,cols=13 text 15,60.5,"31-60 Days",IRFONT,cols=12 text 28,60.5,"61-90 Days",IRFONT,cols=12 text 41,60.5,"Over 90 Days",IRFONT,cols=12 text 54,60.5,"Finance Charge",IRFONT,cols=12 text 67,60.5,"Amount Due",IBRFONT,cols=13 cfont 1,59,13,60,DBRFONT cfont 15,59,26,60,DBRFONT cfont 28,59,39,60,DBRFONT cfont 41,59,52,60,DBRFONT,black cfont 54,59,65,60,DBRFONT,black cfont 67,59,MAXRCOLS,60,DBRFONT,10 [AR_StatementPlain] detect 0,1,"S T A T E M E N T" # set up document constants local MAXCOLS=80 # max cols to output local MAXRCOLS=79 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local CUSTOMER_COPY=1 local REMITTANCE_COPY=2 local FILE_COPY=3 local MAX_COPIES=3 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Statement - plain" # view in pdf properties prejob { doc_title$="STATEMENT" merge "zMrg get watermark text" logocols=12,logorows=6 dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then copy_title$[CUSTOMER_COPY]="Customer Copy" if MAX_COPIES>=2 then copy_title$[REMITTANCE_COPY]="Remittance Copy" if MAX_COPIES>=3 then copy_title$[FILE_COPY]="File Copy" } prepage { xcol=2,xrow=3 merge "zMrg get company info" # add zip barcode xrow=17;xcols=40 #merge "zmrg get zip" } # make space on left & top cmove LEFTCOL,1,RIGHTCOL,MAXROWS,2,2 # default detail line local BROW=1 local EROW=MAXROWS cfont 2,BROW,11,EROW,DBCFONT # date cfont 13,BROW,20,EROW,DFONT # inv # cfont 22,BROW,26,EROW,DCFONT # type cfont 28,BROW,34,EROW,DFONT # check # cfont 36,BROW,46,EROW,DBRFONT # charges cfont 48,BROW,58,EROW,DBRFONT # credits cfont 60,BROW,MAXRCOLS,EROW,DBRFONT # balance # detail section cerase LEFTCOL,16,RIGHTCOL,16 cerase LEFTCOL,18,RIGHTCOL,18 cbox LEFTCOL,16,RIGHTCOL,49,MBOXSIZE,crows=18::DSHADE, ccols=12 21 27 35 47 59 local BROW=17 local EROW=17 cfont 2,BROW,11,EROW,ICFONT # date cfont 13,BROW,20,EROW,IFONT # inv # cfont 22,BROW,26,EROW,ICFONT # type cfont 28,BROW,34,EROW,IFONT # check # cfont 36,BROW,46,EROW,IRFONT # charges cfont 48,BROW,58,EROW,IRFONT # credits cfont 60,BROW,MAXRCOLS,EROW,IRFONT # balance # header section cerase 1,1,MAXCOLS,9 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=9:MBOXSIZE merge "zMrg Form Header" # Invoice block cbox 60,4,RIGHTCOL,9,1,crows=5.5 7.25,ccols=70::ISHADE text 61,5,"Date",IFONT text 61,6.75,"Account #",IFONT text 61,8.5,"Page #",IFONT text 71,5,{trim(cut(60,9,10,""))},DBFONT,10 text 71,6.75,{trim(cut(47,9,10,""))},DBFONT,10 text 71,8.5,{trim(cut(61,3,10,""))},DBFONT,10 # address & balance info cbox LEFTCOL,9,RIGHTCOL,16,MBOXSIZE cfont 1,10,49,15,DBFONT cfont 48,13,52,13,IBFONT,10 cfont 48,14,79,14,DBFONT,10 # zip bar #barcode 3,15,{shipzip$},900,12.0,2 # Messages cbox LEFTCOL,49,RIGHTCOL,53,MBOXSIZE cfont 1,50,MAXCOLS,52,IFONT # watermark - large font with light shading WATERMARK 1,48.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # footer cerase 1,53,MAXCOLS,53 cerase 1,55,MAXCOLS,55 cerase 1,57,MAXCOLS,57 cbox LEFTCOL,53,MAXCOLS,57,MBOXSIZE,crows=55::HSHADE,ccols=11 22 32 42 52 61 cfont 2,54,10,54,IRFONT cfont 12,54,21,54,IRFONT cfont 23,54,31,54,IRFONT cfont 33,54,41,54,IRFONT cfont 43,54,51,54,IRFONT cfont 53,54,60,54,IRFONT cfont 62,54,MAXRCOLS,54,IBRFONT cfont 2,56,10,56,DBRFONT,10 cfont 12,56,21,56,DBRFONT,10 cfont 23,56,31,56,DBRFONT,10 cfont 33,56,41,56,DBRFONT,10,black cfont 43,56,51,56,DBRFONT,10,black cfont 53,56,60,56,DBRFONT,10,black cfont 62,56,MAXRCOLS,56,DBRFONT,11,black cfont LEFTCOL,58,RIGHTCOL,63,IFONT text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS [AR_StatementStd] # This format has "tearoff stub", replaced by remittance copy detect 60,6,"~DATEMASK" detect 88,6,"~DATEMASK" # set up document constants local MAXCOLS=80 # max cols to output local MAXRCOLS=79 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows page 66 local CUSTOMER_COPY=1 local REMITTANCE_COPY=2 local FILE_COPY=3 local MAX_COPIES=3 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Statement - std" # view in pdf properties prejob { doc_title$="STATEMENT" merge "zMrg get watermark text" logocols=12,logorows=6 dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then copy_title$[CUSTOMER_COPY]="Customer Copy" if MAX_COPIES>=2 then copy_title$[REMITTANCE_COPY]="Remittance Copy" if MAX_COPIES>=3 then copy_title$[FILE_COPY]="File Copy" } prepage { xcol=2,xrow=3 merge "zMrg get company info" date$=trim(get(60,6,10)) cust_code$=trim(get(47,6,7)) pageno$=trim(get(60,1,7)) x$=set(1,16,97,"") if trim(get(60,55,20))<>"" then : payby_date$="To avoid additional finance charges, pay by "+trim(get(60,55,20)) endif for i=MAXROWS to 6 step -1 text$[i]=text$[i-5] text$[i-5]="" next i remit$="Remittance Copy - Please return with payment" } # make space on left & top cmove LEFTCOL,1,RIGHTCOL,MAXROWS,1,2 # default detail line local BROW=1 local EROW=MAXROWS cfont 2,BROW,10,EROW,DBCFONT # date cfont 12,BROW,20,EROW,DFONT # inv # cfont 22,BROW,24,EROW,DCFONT # type cfont 26,BROW,34,EROW,DFONT # check # cfont 36,BROW,47,EROW,DBRFONT # charges cfont 49,BROW,58,EROW,DBRFONT # credits cfont 60,BROW,79,EROW,DBRFONT # balance # detail section #cerase LEFTCOL,16,RIGHTCOL,16 #cerase LEFTCOL,18,RIGHTCOL,18 cbox LEFTCOL,20,RIGHTCOL,51,MBOXSIZE,crows=21.5::DSHADE, ccols=11 21 25 35 48 59 local BROW=21 local EROW=21 text 1,21,"Invoice Date",ICFONT,cols=10 text 12,21,"Invoice No",IFONT text 22,21,"Type",ICFONT,cols=3 text 26,21,"Check No",IFONT text 36,21,"Charges",IRFONT,cols=12 text 49,21,"Credits",IRFONT,cols=10 text 60,21,"Balance",IRFONT,cols=20 # header section cerase 1,1,MAXCOLS,12 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=9:MBOXSIZE merge "zMrg Form Header" # Invoice block cbox 60,4,RIGHTCOL,9,1,crows=5.5 7.25,ccols=70::ISHADE text 61,5,"Date",IFONT text 61,6.75,"Account #",IFONT text 61,8.5,"Page #",IFONT text 71,5,{date$},DBFONT,10 text 71,6.75,{cust_code$},DBFONT,10 text 71,8.5,{pageno$},DBFONT,10 # address & balance info cerase 75,11,97,51 cbox LEFTCOL,9,RIGHTCOL,20,MBOXSIZE cfont 1,10,49,19,DBFONT text 65,15,"Terms",IBFONT cfont 47,15,79,15,DBRFONT # Messages cbox LEFTCOL,51,MAXCOLS,57,MBOXSIZE cfont 1,52,MAXCOLS,56,IFONT # watermark - large font with light shading WATERMARK 1,50.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # aging table cerase 75,58,97,58 cerase 1,60,97,MAXROWS cbox LEFTCOL,57,MAXCOLS,60,MBOXSIZE,crows=58.5::HSHADE,ccols=10 21 31 41 52 62 text 1,58,"Unpaid F/C",IRFONT,cols=9 text 11,58,"Current",IRFONT,cols=10 text 22,58,"31-60 Days",IRFONT,cols=9 text 32,58,"61-90 Days",IRFONT,cols=9 text 42,58,"Over 90 Days",IRFONT,cols=10 text 52,58,"New F/C",IRFONT,cols=10 text 63,58,"Amount Due",IBRFONT,cols=16 cfont 1,59,9,59,DBRFONT cfont 11,59,20,59,DBRFONT,black cfont 22,59,30,59,DBRFONT cfont 32,59,40,59,DBRFONT,black cfont 42,59,50,59,DBRFONT cfont 52,59,61,59,DBRFONT,black cfont 63,59,79,59,DBRFONT text 2,63,{payby_date$},HFONT text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS [DD_DirDepBlank] detect 0,1,"D I R E C T D E P O S I T V O U C H E R" detect 0,7,"! * VOID * " detect 0,8,"~ DATEMASK" detect 0,25,"~ [0-9][0-9]/[0-9][0-9]/[0-9][0-9] [0-9][0-9]/[0-9][0-9]/[0-9][0-9] " # set up document constants const MAXCOLS=81 const MAXRCOLS=80 const MAXROWS=66 const LEFTCOL=1 # left vertical line const RIGHTCOL=81 # right vertical line cols MAXCOLS rows MAXROWS page 42 portrait dpi 600 # see global constant above GSON # graphical shading title "DD Direct Deposit - Blank" # view in pdf properties prejob { logocols=10,logorows=5 } prepage { compname$=cut(10,23,15,"") vacsickrem$=mcut(1,38,14,2,"","Y","Y") vacsickamt$=mcut(17,38,9,2,"","Y","Y") brow=24,erow=43 begin_copy_loop: text$[brow+20]=text$[brow] brow=brow+1 if brow=erow then goto end_copy_loop else goto begin_copy_loop end_copy_loop: } # make space on left cmove 1,1,MAXCOLS,MAXROWS,2,1 # clear header cerase 1,1,MAXCOLS,7 # Check LOGO_IMAGE 1,1,10,5,"COMP_LOGO" cbox LEFTCOL,1,RIGHTCOL,17.75,MBOXSIZE text 15,2.25,{compname$},HBFONT,14 text 15,3.35,"COMP_ADDR1",HFONT,12 text 15,4.35,"COMP_ADDR2",HFONT,12 text 15,5.35,"COMP_ADDR3",HFONT,12 text 49,2.25,"PR_BANK_NAME",DBFONT text 49,3.05,"PR_BANK_ADDR1",DFONT text 49,3.85,"PR_BANK_ADDR2",DFONT text 70,3.35,"PR_ROUTING",DBFONT # rtg # cfont 21,8,57,8,DFONT,11 cfont 61,8,69,8,DFONT,11 cfont 1,8,MAXCOLS,8,DCFONT,11 cfont 2,10,9,12,DFONT,10 cfont 11,10,27,12,DRFONT,10 cfont 29,10,38,12,DBRFONT,10 cfont 42,10,49,12,DFONT,10 cfont 51,10,67,12,DRFONT,10 cfont 69,10,78,12,DBRFONT,10 shade "~\.[0-9][0-9]@36,10,38,12",-34,0,26,1,DSHADE shade "~\.[0-9][0-9]@76,10,78,12",-34,0,26,1,DSHADE text 2,14,"Pay",IFONT text 2,15,"to the",IFONT text 2,16,"Order",IFONT text 2,17,"of",IFONT cmove 6,14,47,17,6,14 cfont 7,13,51,16,DBFONT,11 text 51,16,"DIRECT DEPOSIT ADVICE SLIP",HBCFONT,12,cols=30 text 51,17,"NON-NEGOTIABLE",HBCFONT,cols=30 cfont 58,14,66,14,DFONT cfont 68,14,77,14,DBRFONT # top stub - employee's cerase 1,22,30,22 cbox LEFTCOL,21,MAXCOLS,21 text 15,22,{compname$},HBFONT,12 cbox LEFTCOL,22.5,MAXCOLS,24.5,MBOXSIZE,crows=23.5::DSHADE, ccols=15 33 45 54 64 cfont 2,23,14,23,ICFONT,8,proper cfont 16,23,32,23,ICFONT,8,proper cfont 34,23,44,23,ICFONT,8,proper cfont 46,23,53,23,ICFONT,8,proper cfont 55,23,63,23,ICFONT,8,proper cfont 65,23,MAXRCOLS,23,ICFONT,8,proper cfont 2,24,14,24,DBCFONT cfont 16,24,32,24,DBCFONT cfont 34,24,44,24,DBCFONT cfont 46,24,53,24,DBCFONT cfont 55,24,63,24,DBCFONT cfont 65,24,MAXRCOLS,24,DBCFONT cmove LEFTCOL,24,MAXCOLS,25,LEFTCOL,23 cmove LEFTCOL,27,MAXCOLS,42,LEFTCOL,25 cbox LEFTCOL,24.5,MAXCOLS,38.5,MBOXSIZE,crows=25.5::DSHADE, ccols=14 24 34 47 60 70 cfont 2,25,13,25,IFONT,8,proper cfont 14,25,23,25,IRFONT,8,black,proper cfont 24,25,33,25,IRFONT,8,proper cfont 35,25,46,25,IRFONT,8,proper cfont 48,25,59,25,IFONT,8,proper cfont 61,25,69,25,IRFONT,8,proper cfont 71,25,MAXRCOLS,25,IRFONT,8,proper cfont 2,26,14,35,DFONT cfont 14,26,23,35,DBRFONT,black cfont 24,26,33,35,DBRFONT cfont 35,26,46,35,DBRFONT cfont 48,26,59,36,DFONT cfont 61,26,69,36,DBRFONT cfont 71,26,MAXRCOLS,36,DBRFONT #Vac and sick remaining cfont 2,36,15,38,IFONT cfont 16,36,23,38,DBRFONT text 2,36,{vacsickrem$},IBFONT text 15,36,{vacsickamt$},DBRFONT,cols=9 cbox LEFTCOL,38.5,MAXCOLS,40.5,MBOXSIZE,crows=39.5::100, ccols=13 25 37 48 60 71 cfont 2,39,12,39,IFONT,8,shade=0 cfont 14,39,24,39,IRFONT,8,shade=0 cfont 26,39,36,39,IRFONT,8,shade=0 cfont 38,39,47,39,IRFONT,8,shade=0 cfont 49,39,59,39,IRFONT,8,shade=0 cerase 61,39,MAXCOLS,39 text 61,39,"YTD Ded",IRFONT,8,shade=0,cols=10 text 72,39,"YTD Net Pay",IRFONT,8,shade=0,cols=9 cfont 2,40,12,40,DBFONT cfont 14,40,24,40,DBRFONT cfont 26,40,36,40,DBRFONT cfont 38,40,47,40,DBRFONT cfont 49,40,59,40,DBRFONT cfont 61,40,70,40,DBRFONT cfont 72,40,MAXRCOLS,40,DBRFONT # Bottom stub - employer's cbox LEFTCOL,42,MAXCOLS,42 text 15,43,{compname$},HBFONT,12 cbox LEFTCOL,43.5,MAXCOLS,45.5,MBOXSIZE,crows=44.5::DSHADE, ccols=15 33 45 54 64 cfont 2,44,14,44,ICFONT,8,proper cfont 16,44,32,44,ICFONT,8,proper cfont 34,44,44,44,ICFONT,8,proper cfont 46,44,53,44,ICFONT,8,proper cfont 55,44,63,44,ICFONT,8,proper cfont 65,44,MAXRCOLS,44,ICFONT,8,proper cfont 2,45,14,45,DBCFONT cfont 16,45,32,45,DBCFONT cfont 34,45,44,45,DBCFONT cfont 46,45,53,45,DBCFONT cfont 55,45,63,45,DBCFONT cfont 65,45,MAXRCOLS,45,DBCFONT cmove LEFTCOL,47,MAXCOLS,62,LEFTCOL,46 cbox LEFTCOL,45.5,MAXCOLS,59.5,MBOXSIZE,crows=46.5::DSHADE, ccols=14 24 34 47 60 70 cfont 2,46,13,46,IFONT,8,proper cfont 14,46,23,46,IRFONT,8,black,proper cfont 24,46,33,46,IRFONT,8,proper cfont 35,46,46,46,IRFONT,8,proper cfont 48,46,59,46,IFONT,8,proper cfont 61,46,69,46,IRFONT,8,proper cfont 71,46,MAXRCOLS,46,IRFONT,8,proper cfont 2,47,13,56,DFONT cfont 14,47,23,56,DBRFONT,black cfont 24,47,33,56,DBRFONT cfont 35,47,46,56,DBRFONT cfont 48,47,59,59,DFONT cfont 61,47,69,59,DBRFONT cfont 71,47,MAXRCOLS,59,DBRFONT text 2,57,{vacsickrem$},IBFONT text 15,57,{vacsickamt$},DBRFONT,cols=9 cbox LEFTCOL,59.5,MAXCOLS,61.5,MBOXSIZE,crows=60.5::100, ccols=13 25 37 48 60 71 cfont 2,60,12,60,IFONT,8,shade=0 cfont 14,60,24,60,IRFONT,8,shade=0 cfont 26,60,36,60,IRFONT,8,shade=0 cfont 38,60,47,60,IRFONT,8,shade=0 cfont 49,60,59,60,IRFONT,8,shade=0 cerase 61,60,MAXCOLS,60 text 61,60,"YTD Ded",IRFONT,shade=0,cols=10 text 72,60,"YTD Net Pay",IRFONT,shade=0,cols=9 cfont 2,61,12,61,DBFONT cfont 14,61,24,61,DBRFONT cfont 26,61,36,61,DBRFONT cfont 38,61,47,61,DBRFONT cfont 49,61,59,61,DBRFONT cfont 61,61,70,61,DBRFONT cfont 72,61,MAXRCOLS,61,DBRFONT [DD_DirDepLaser] detect 0,1,"D I R E C T D E P O S I T V O U C H E R" detect 0,8,"~ DATEMASK" detect 0,22,"~ [0-9][0-9]/[0-9][0-9]/[0-9][0-9] [0-9][0-9]/[0-9][0-9]/[0-9][0-9] " # set up document constants const MAXCOLS=81 const MAXRCOLS=80 const MAXROWS=66 const LEFTCOL=1 # left vertical line const RIGHTCOL=81 # right vertical line cols MAXCOLS rows MAXROWS const MAX_COPIES=1 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "DD Direct Deposit - Laser" # view in pdf properties prejob { compname$=cut(10,20,15,"") logocols=10,logorows=5 } precopy { } # make space on left cmove 1,1,MAXCOLS,MAXROWS,2,1 # first adjust format to standard cmove 1,20,MAXCOLS,60,1,22 cerase 1,1,35,6 # Check LOGO_IMAGE 1,1,10,4,"COMP_LOGO" cbox LEFTCOL,1,RIGHTCOL,17.75,MBOXSIZE text 15,2.25,{compname$},HBFONT,14 text 15,3.35,"COMP_ADDR1",HFONT,12 text 15,4.35,"COMP_ADDR2",HFONT,12 text 15,5.35,"COMP_ADDR3",HFONT,12 text 49,2.25,"PR_BANK_NAME",DBFONT text 49,3.05,"PR_BANK_ADDR1",DFONT text 49,3.85,"PR_BANK_ADDR2",DFONT text 70,3.35,"PR_ROUTING",DBFONT # rtg # text 2,7,"Pay",IFONT,14 text 7,7,{trim(cut(4,7,80,""))},DBFONT,italic,11,fit cfont 1,8,MAXCOLS,8,DCFONT,11 cfont 2,9,9,11,DFONT,10 cfont 11,9,27,11,DRFONT,10 cfont 29,9,38,11,DBRFONT,10 cfont 42,9,49,11,DFONT,10 cfont 51,9,67,11,DRFONT,10 cfont 69,9,78,11,DBRFONT,10 shade "~\.[0-9][0-9]@36,9,38,11",-34,0,26,1,DSHADE shade "~\.[0-9][0-9]@76,9,78,11",-34,0,26,1,DSHADE cfont 59,12,66,12,DRFONT,10 cfont 68,12,78,12,DBRFONT,10 text 2,14,"Pay",IFONT text 2,15,"to the",IFONT text 2,16,"Order",IFONT text 2,17,"of",IFONT cmove 6,12,47,14,6,14 cfont 7,13,51,17,DBFONT,11 # direct deposit on line 1 cerase 1,1,MAXCOLS,1 text 51,16,"DIRECT DEPOSIT ADVICE SLIP",HBCFONT,12,cols=30 text 51,17,"NON-NEGOTIABLE",HBCFONT,cols=30 # top stub - employee's cerase 1,22,30,22 cbox LEFTCOL,21,MAXCOLS,21 text 15,22,{compname$},HBFONT,12 cbox LEFTCOL,22.5,MAXCOLS,24.5,MBOXSIZE,crows=23.5::DSHADE, ccols=15 33 45 54 64 cfont 2,23,14,23,ICFONT,8,proper cfont 16,23,32,23,ICFONT,8,proper cfont 34,23,44,23,ICFONT,8,proper cfont 46,23,53,23,ICFONT,8,proper cfont 55,23,63,23,ICFONT,8,proper cfont 65,23,MAXRCOLS,23,ICFONT,8,proper cfont 2,24,14,24,DBCFONT cfont 16,24,32,24,DBCFONT cfont 34,24,44,24,DBCFONT cfont 46,24,53,24,DBCFONT cfont 55,24,63,24,DBCFONT cfont 65,24,MAXRCOLS,24,DBCFONT cbox LEFTCOL,24.5,MAXCOLS,38.5,MBOXSIZE,crows=25.5::DSHADE, ccols=14 23 34 47 60 70 cfont 2,25,13,25,IFONT,8,proper text 14,25,{proper(cut(14,23,10,""))},IRFONT,8,proper,cols=9 cfont 24,25,33,25,IRFONT,8,proper cfont 35,25,46,25,IRFONT,8,proper cfont 48,25,59,25,ILFONT,8,proper cfont 61,25,69,25,IRFONT,8,proper cfont 71,25,MAXRCOLS,25,IRFONT,8,proper cfont 2,26,13,35,DFONT cfont 14,26,22,35,DBRFONT,black cfont 24,26,33,35,DBRFONT cfont 35,26,46,35,DBRFONT cfont 48,26,59,38,DFONT cfont 61,26,69,38,DBRFONT cfont 71,26,MAXRCOLS,38,DBRFONT text 2,36,{mcut(1,34,15,2,"","Y","Y")},IBFONT text 14,36,{mcut(17,34,9,2,"","Y","Y")},DBRFONT,cols=9 cbox LEFTCOL,38.5,MAXCOLS,40.5,MBOXSIZE,crows=39.5::100, ccols=13 25 37 48 60 71 cfont 2,39,12,39,IFONT,8,shade=0 cfont 14,39,24,39,IRFONT,8,shade=0 cfont 26,39,36,39,IRFONT,8,shade=0 cfont 38,39,47,39,IRFONT,8,shade=0 cfont 49,39,59,39,IRFONT,8,shade=0 cerase 61,39,MAXCOLS,39 text 61,39,"YTD Ded",IRFONT,8,shade=0,cols=10 text 72,39,"YTD Net Pay",IRFONT,8,shade=0,cols=9 cfont 2,40,12,40,DBFONT cfont 14,40,24,40,DBRFONT cfont 26,40,36,40,DBRFONT cfont 38,40,47,40,DBRFONT cfont 49,40,59,40,DBRFONT cfont 61,40,70,40,DBRFONT cfont 72,40,MAXRCOLS,40,DBRFONT # Bottom stub - employer's cerase 1,43,30,43 cbox LEFTCOL,42,MAXCOLS,42 text 15,43,"COMP_NAME",HBFONT,12 cbox LEFTCOL,43.5,MAXCOLS,45.5,MBOXSIZE,crows=44.5::DSHADE, ccols=15 33 45 54 64 cfont 2,44,14,44,ICFONT,8,proper cfont 16,44,32,44,ICFONT,8,proper cfont 34,44,44,44,ICFONT,8,proper cfont 46,44,53,44,ICFONT,8,proper cfont 55,44,63,44,ICFONT,8,proper cfont 65,44,MAXRCOLS,44,ICFONT,8,proper cfont 2,45,14,45,DBCFONT cfont 16,45,32,45,DBCFONT cfont 34,45,44,45,DBCFONT cfont 46,45,53,45,DBCFONT cfont 55,45,63,45,DBCFONT cfont 65,45,MAXRCOLS,45,DBCFONT cbox LEFTCOL,45.5,MAXCOLS,59.5,MBOXSIZE,crows=46.5::DSHADE, ccols=14 23 34 47 60 70 cfont 2,46,13,46,IFONT,8,proper text 14,46,{proper(cut(14,44,10,""))},IRFONT,8,proper,cols=9 cfont 24,46,33,46,IRFONT,8,proper cfont 35,46,46,46,IRFONT,8,proper cfont 48,46,59,46,ILFONT,8,proper cfont 61,46,69,46,IRFONT,8,proper cfont 71,46,MAXRCOLS,46,IRFONT,8,proper cfont 2,47,13,56,DFONT cfont 14,47,22,56,DBRFONT,black cfont 24,47,33,56,DBRFONT cfont 35,47,46,56,DBRFONT cfont 48,47,59,59,DFONT cfont 61,47,69,59,DBRFONT cfont 71,47,MAXRCOLS,59,DBRFONT text 2,57,{mcut(1,55,15,2,"","Y","Y")},IBFONT text 14,57,{mcut(17,55,9,2,"","Y","Y")},DBRFONT,cols=9 cbox LEFTCOL,59.5,MAXCOLS,61.5,MBOXSIZE,crows=60.5::100, ccols=13 25 37 48 60 71 cfont 2,60,12,60,IFONT,8,shade=0 cfont 14,60,24,60,IRFONT,8,shade=0 cfont 26,60,36,60,IRFONT,8,shade=0 cfont 38,60,47,60,IRFONT,8,shade=0 cfont 49,60,59,60,IRFONT,8,shade=0 cerase 61,60,MAXCOLS,60 text 61,60,"YTD Ded",IRFONT,shade=0,cols=10 text 72,60,"YTD Net Pay",IRFONT,shade=0,cols=9 cfont 2,61,12,61,DBFONT cfont 14,61,24,61,DBRFONT cfont 26,61,36,61,DBRFONT cfont 38,61,47,61,DBRFONT cfont 49,61,59,61,DBRFONT cfont 61,61,70,61,DBRFONT cfont 72,61,MAXRCOLS,61,DBRFONT #*************************************************************** # Less frequently used rule sets * #*************************************************************** [DD_DirDepPreprinted] detect 0,1,"D I R E C T D E P O S I T V O U C H E R" detect 0,8,"~ DATEMASK" detect 0,25,"~ [0-9][0-9]/[0-9][0-9]/[0-9][0-9] [0-9][0-9]/[0-9][0-9]/[0-9][0-9] " # set up document constants const MAXCOLS=81 const MAXRCOLS=80 const MAXROWS=66 const LEFTCOL=1 # left vertical line const RIGHTCOL=81 # right vertical line cols MAXCOLS rows MAXROWS page 42 const MAX_COPIES=1 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "DD Direct Deposit - Preprinted" # view in pdf properties prejob { logocols=10,logorows=5 } prepage { compname$=cut(10,23,15,"") vacsickrem$=mcut(1,38,14,2,"","Y","Y") vacsickamt$=mcut(17,38,9,2,"","Y","Y") brow=24,erow=43 begin_copy_loop: text$[brow+20]=text$[brow] brow=brow+1 if brow=erow then goto end_copy_loop else goto begin_copy_loop end_copy_loop: } # make space on left cmove 1,1,MAXCOLS,MAXROWS,2,1 # clear header cerase 1,1,MAXCOLS,7 # check LOGO_IMAGE 1,1,10,4,"COMP_LOGO" cbox LEFTCOL,1,RIGHTCOL,17.75,MBOXSIZE text 15,2.25,{compname$},HBFONT,14 text 15,3.35,"COMP_ADDR1",HFONT,12 text 15,4.35,"COMP_ADDR2",HFONT,12 text 15,5.35,"COMP_ADDR3",HFONT,12 text 49,2.25,"PR_BANK_NAME",DBFONT text 49,3.05,"PR_BANK_ADDR1",DFONT text 49,3.85,"PR_BANK_ADDR2",DFONT text 70,3.35,"PR_ROUTING",DBFONT # rtg # cfont 22,8,57,8,DLFONT,11 cfont 57,8,69,8,DFONT,11 cfont 1,8,MAXCOLS,8,DCFONT,11 cfont 2,10,9,12,DFONT,10 cfont 11,10,27,12,DRFONT,10 cfont 29,10,38,12,DBRFONT,10 cfont 42,10,49,12,DFONT,10 cfont 51,10,67,12,DRFONT,10 cfont 69,10,78,12,DBRFONT,10 shade "~\.[0-9][0-9]@36,10,38,12",-34,0,26,1,DSHADE shade "~\.[0-9][0-9]@76,10,78,12",-34,0,26,1,DSHADE text 2,14,"Pay",IFONT text 2,15,"to the",IFONT text 2,16,"Order",IFONT text 2,17,"of",IFONT cfont 7,13,51,16,DBFONT,11 text 51,16,"DIRECT DEPOSIT ADVICE SLIP",HBCFONT,12,cols=30 text 51,17,"NON-NEGOTIABLE",HBCFONT,cols=30 cfont 58,14,66,14,DFONT cfont 68,14,77,14,DBRFONT # top stub - employee's cbox LEFTCOL,21,MAXCOLS,21 text 15,22,{compname$},HBFONT,12 cbox LEFTCOL,22.5,MAXCOLS,24.5,MBOXSIZE,crows=23.5::DSHADE, ccols=15 33 45 54 64 cfont 2,23,14,23,ICFONT,9,proper cfont 16,23,32,23,ICFONT,9,proper cfont 34,23,44,23,ICFONT,9,proper cfont 46,23,53,23,ICFONT,9,proper cfont 55,23,63,23,ICFONT,9,proper cfont 65,23,MAXRCOLS,23,9,ICFONT,proper cfont 2,24,14,24,DBCFONT cfont 16,24,32,24,DBCFONT cfont 34,24,44,24,DBCFONT cfont 46,24,53,24,DBCFONT cfont 55,24,63,24,DBCFONT cfont 65,24,MAXRCOLS,24,DBCFONT cmove LEFTCOL,24,MAXCOLS,25,LEFTCOL,23 cmove LEFTCOL,27,MAXCOLS,42,LEFTCOL,25 cbox LEFTCOL,24.5,MAXCOLS,38.5,MBOXSIZE,crows=25.5::DSHADE, ccols=14 24 34 47 60 70 cfont 2,25,13,25,IFONT,9,proper cfont 14,25,23,25,IRFONT,9,black,proper cfont 24,25,33,25,IRFONT,9,proper cfont 35,25,46,25,IRFONT,9,proper cfont 48,25,59,25,IFONT,9,proper cfont 61,25,69,25,IRFONT,9,proper cfont 71,25,MAXRCOLS,25,IRFONT,9,proper cfont 2,26,14,35,DFONT cfont 14,26,23,35,DBRFONT,black cfont 24,26,33,35,DBRFONT cfont 35,26,46,35,DBRFONT cfont 48,26,59,36,DFONT cfont 61,26,69,36,DBRFONT cfont 71,26,MAXRCOLS,36,DBRFONT text 2,36,{vacsickrem$},IBFONT,9 text 15,36,{vacsickamt$},DBRFONT,cols=9 cbox LEFTCOL,38.5,MAXCOLS,40.5,MBOXSIZE,crows=39.5::100, ccols=13 25 37 48 60 71 cfont 2,39,12,39,IFONT,9,shade=0 cfont 14,39,24,39,IRFONT,9,shade=0 cfont 26,39,36,39,IRFONT,9,shade=0 cfont 38,39,47,39,IRFONT,9,shade=0 cfont 49,39,59,39,IRFONT,9,shade=0 cerase 61,39,MAXCOLS,39 text 61,39,"YTD Ded",IRFONT,9,shade=0,cols=10 text 72,39,"YTD Net Pay",IRFONT,9,shade=0,cols=9 cfont 2,40,12,40,DBFONT cfont 14,40,24,40,DBRFONT cfont 26,40,36,40,DBRFONT cfont 38,40,47,40,DBRFONT cfont 49,40,59,40,DBRFONT cfont 61,40,70,40,DBRFONT cfont 72,40,MAXRCOLS,40,DBRFONT # Bottom stub - employer's cbox LEFTCOL,42,MAXCOLS,42 text 15,43,{compname$},HBFONT,12 cbox LEFTCOL,43.5,MAXCOLS,45.5,MBOXSIZE,crows=44.5::DSHADE, ccols=15 33 45 54 64 cfont 2,44,14,44,ICFONT,9,proper cfont 16,44,32,44,ICFONT,9,proper cfont 34,44,44,44,ICFONT,9,proper cfont 46,44,53,44,ICFONT,9,proper cfont 55,44,63,44,ICFONT,9,proper cfont 65,44,MAXRCOLS,44,ICFONT,9,proper cfont 2,45,14,45,DBCFONT cfont 16,45,32,45,DBCFONT cfont 34,45,44,45,DBCFONT cfont 46,45,53,45,DBCFONT cfont 55,45,63,45,DBCFONT cfont 65,45,MAXRCOLS,45,DBCFONT cmove LEFTCOL,47,MAXCOLS,62,LEFTCOL,46 cbox LEFTCOL,45.5,MAXCOLS,59.5,MBOXSIZE,crows=46.5::DSHADE, ccols=14 24 34 47 60 70 cfont 2,46,13,46,IFONT,9,proper cfont 14,46,23,46,IRFONT,9,black,proper cfont 24,46,33,46,IRFONT,9,proper cfont 35,46,46,46,IRFONT,9,proper cfont 48,46,59,46,IFONT,9,proper cfont 61,46,69,46,IRFONT,9,proper cfont 71,46,MAXRCOLS,46,IRFONT,9,proper cfont 2,47,13,56,DFONT cfont 14,47,23,56,DBRFONT,black cfont 24,47,33,56,DBRFONT cfont 35,47,46,56,DBRFONT cfont 48,47,59,59,DFONT cfont 61,47,69,59,DBRFONT cfont 71,47,MAXRCOLS,59,DBRFONT text 2,57,{vacsickrem$},IBFONT,9 text 15,57,{vacsickamt$},DBRFONT,cols=9 cbox LEFTCOL,59.5,MAXCOLS,61.5,MBOXSIZE,crows=60.5::100, ccols=13 25 37 48 60 71 cfont 2,60,12,60,IFONT,shade=0 cfont 14,60,24,60,IRFONT,shade=0 cfont 26,60,36,60,IRFONT,shade=0 cfont 38,60,47,60,IRFONT,shade=0 cfont 49,60,59,60,IRFONT,shade=0 cerase 61,60,MAXCOLS,60 text 61,60,"YTD Ded",IRFONT,shade=0,cols=10 text 72,60,"YTD Net Pay",IRFONT,shade=0,cols=9 cfont 2,61,12,61,DBFONT cfont 14,61,24,61,DBRFONT cfont 26,61,36,61,DBRFONT cfont 38,61,47,61,DBRFONT cfont 49,61,59,61,DBRFONT cfont 61,61,70,61,DBRFONT cfont 72,61,MAXRCOLS,61,DBRFONT [GL_BalanceSheet] detect 0,3,"~BALANCE SHEET WITH .* COMPARISON" detect 0,3,"~(BUDGET)|(LAST YEAR)" # set up document constants local MAXCOLS=80 # max cols to output local MAXRCOLS=79 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local MAX_COPIES=1 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Balance Sheet" # view in pdf properties cmove LEFTCOL,1,MAXCOLS,MAXROWS,2,1 # default detail line local BROW=1 local EROW=MAXROWS cfont 2,BROW,16,EROW,DBCFONT # acnt no cfont 18,BROW,46,EROW,DFONT # desc cfont 48,BROW,60,EROW,DBRFONT # curr yr cfont 61,BROW,59,EROW,DBFONT,black # ) cfont 64,BROW,76,EROW,DBRFONT # prev yr/budget cfont 77,BROW,77,EROW,DBFONT,black # ) # header cerase LEFTCOL,1,MAXCOLS,4 cbox LEFTCOL,.1,RIGHTCOL,4,MBOXSIZE,HSHADE text 2,1.5,{trim(cut(1,1,10,""))},HFONT text 1,1.5,{trim(cut(18,1,50,""))},HBCFONT,14,cols=MAXCOLS text 1,1.5,{trim(cut(70,1,10,""))},HRFONT,cols=MAXRCOLS text 2,2.5,{trim(cut(1,2,10,""))},HFONT text 1,2.75,{trim(cut(1,3,MAXCOLS,""))},HBCFONT,12,cols=MAXCOLS text 1,3.75,{trim(cut(1,4,MAXCOLS,""))},HCFONT,cols=MAXCOLS # detail header line cerase 1,10,MAXCOLS,10 cbox LEFTCOL,6,MAXCOLS,8.5,1,DSHADE local BROW=7 local EROW=8 cfont 2,BROW,16,EROW,ICFONT,proper # acnt no cfont 18,BROW,46,EROW,IFONT,proper # desc cfont 48,BROW,60,EROW,IRFONT,black,proper # curr yr cfont 64,BROW,76,EROW,IRFONT,proper # prev yr/budget # special detail lines font "~ [A-Z]@23,11,25,MAXROWS",2,0,50,1,DBFONT,11 font "~ [A-Z]@14,11,16,MAXROWS",2,0,50,1,IBFONT,10 font "~ TOTAL@18,11,24,MAXROWS",2,0,27,1,IBFONT,10 box "~ TOTAL@18,11,24,MAXROWS",1,-.85,58,1.4,1,DSHADE erase "~ TOTAL@18,11,24,MAXROWS",0,-1,MAXCOLS,1 erase "~ TOTAL@18,11,24,MAXROWS",0,1,MAXCOLS,1 # unaudited font "UNAUDITED",0,0,9,1,HFONT [GL_IncStmtwBudgComp] detect 0,3,"~INCOME STATEMENT WITH BUDGET COMPARISON" # set up document constants local MAXCOLS=130 # max cols to output local MAXRCOLS=129 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=60 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local MAX_COPIES=1 pcopies MAX_COPIES landscape dpi 600 # see global constant above GSON # graphical shading title "Income Statement with Budget Comp" # view in pdf properties cmove LEFTCOL,1,MAXCOLS,MAXROWS,2,1 # default detail line local BROW=1 local EROW=MAXROWS cfont 2,BROW,7,EROW,DBCFONT # acnt no cfont 9,BROW,40,EROW,DFONT # desc # current period cfont 41,BROW,52,EROW,DBRFONT,black # this yr cfont 53,BROW,53,EROW,DBFONT # - cfont 55,BROW,60,EROW,DRFONT # % cfont 61,BROW,61,EROW,DFONT,black # - cfont 63,BROW,75,EROW,DBRFONT # budget cfont 76,BROW,76,EROW,DBFONT,black # - cfont 78,BROW,83,EROW,DRFONT # % cfont 84,BROW,84,EROW,DFONT,black # - #year to date cfont 86,BROW,98,EROW,DBRFONT # this yr cfont 99,BROW,99,EROW,DBFONT,black # - cfont 101,BROW,106,EROW,DRFONT # % cfont 107,BROW,107,EROW,DFONT,black # - cfont 109,BROW,121,EROW,DBRFONT # budget cfont 122,BROW,122,EROW,DBFONT,black # - cfont 124,BROW,129,EROW,DRFONT # % cfont 130,BROW,130,EROW,DFONT,black # - # header cerase LEFTCOL,1,MAXCOLS,4 cbox LEFTCOL,.1,RIGHTCOL,4,MBOXSIZE,HSHADE text 2,1.5,{trim(cut(1,1,10,""))},HFONT text 1,1.5,{trim(cut(18,1,92,""))},HBCFONT,14,cols=MAXCOLS text 1,1.5,{trim(cut(121,1,10,""))},HRFONT,cols=MAXRCOLS text 2,2.5,{trim(cut(1,2,10,""))},HFONT text 1,2.75,{trim(cut(1,3,MAXCOLS,""))},HBCFONT,12,cols=MAXCOLS text 1,3.75,{trim(cut(1,4,MAXCOLS,""))},HCFONT,cols=MAXCOLS # detail header line cerase 1,10,MAXCOLS,10 cbox LEFTCOL,6,MAXCOLS,8.5,1,DSHADE local BROW=7 local EROW=8 cfont 2,BROW,7,EROW,ICFONT,proper # acnt no cfont 9,BROW,40,EROW,IFONT,proper # desc cfont 41,7,83,7,ICFONT,black # current period local BROW=8 local EROW=8 cbox 42,7.375,83.5,7.375 cfont 41,BROW,52,EROW,IRFONT,black,proper # this yr cfont 55,BROW,60,EROW,IRFONT # % cfont 63,BROW,75,EROW,IRFONT,proper # budget cfont 78,BROW,83,EROW,IRFONT # % # year to date cbox 88,7.375,129.5,7.375 cfont 86,7,129,7,ICFONT,black cfont 86,BROW,98,EROW,IRFONT,proper # this yr cfont 101,BROW,106,EROW,IRFONT # % cfont 109,BROW,121,EROW,IRFONT,proper # budget cfont 124,BROW,129,EROW,IRFONT # % # special detail lines font "~ [A-Z]@7,11,9,MAXROWS",2,0,50,1,DBFONT,11 font "~ [A-Z]@8,11,10,MAXROWS",2,0,50,1,DBFONT,10 font "~ TOTAL@10,11,16,MAXROWS",2,0,27,1,IBFONT,10 box "~ TOTAL@10,11,16,MAXROWS",1,-.85,119,1.4,1,DSHADE erase "~ TOTAL@10,11,16,MAXROWS",0,-1,MAXCOLS,1 erase "~ TOTAL@10,11,16,MAXROWS",0,1,MAXCOLS,1 font "~ TOTAL@11,11,17,MAXROWS",2,0,27,1,IBFONT,10 box "~ TOTAL@11,11,17,MAXROWS",1,-.85,118,1.4,1,DSHADE erase "~ TOTAL@11,11,17,MAXROWS",0,-1,MAXCOLS,1 erase "~ TOTAL@11,11,17,MAXROWS",0,1,MAXCOLS,1 font "~ GROSS@11,11,17,MAXROWS",2,0,27,1,IBFONT,10 box "~ GROSS@11,11,17,MAXROWS",1,-.85,118,1.4,1,HSHADE font "~ PROFI@11,11,17,MAXROWS",2,0,27,1,IBFONT,10 box "~ PROFI@11,11,17,MAXROWS",1,-.85,118,1.4,1,HSHADE font "~ NET@11,11,15,MAXROWS",2,0,27,1,IBFONT,10 box "~ NET@11,11,15,MAXROWS",1,-.85,118,1.4,1,HSHADE # unaudited font "UNAUDITED",0,0,9,1,HFONT [GL_IncStmtwLstYrComp] detect 0,3,"~INCOME STATEMENT WITH LAST YEAR COMPARISON" # set up document constants local MAXCOLS=128 # max cols to output local MAXRCOLS=127 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=60 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local MAX_COPIES=1 pcopies MAX_COPIES landscape dpi 600 # see global constant above GSON # graphical shading title "Income Statement with Last Year Comp" # view in pdf properties cmove LEFTCOL,1,MAXCOLS,MAXROWS,2,1 # default detail line local BROW=1 local EROW=MAXROWS cfont 2,BROW,7,EROW,DBCFONT # acnt no cfont 9,BROW,37,EROW,DFONT # desc # current period cfont 38,BROW,49,EROW,DBRFONT,black # this yr cfont 50,BROW,50,EROW,DBFONT # - cfont 52,BROW,57,EROW,DRFONT # % cfont 58,BROW,58,EROW,DFONT,black # - cfont 60,BROW,71,EROW,DBRFONT # prev yr cfont 72,BROW,72,EROW,DBFONT,black # - cfont 74,BROW,81,EROW,DRFONT # % cfont 82,BROW,82,EROW,DFONT,black # - # year to date cfont 84,BROW,95,EROW,DBRFONT # this yr cfont 96,BROW,96,EROW,DBFONT,black # - cfont 98,BROW,103,EROW,DRFONT # % cfont 104,BROW,104,EROW,DFONT,black # - cfont 106,BROW,117,EROW,DBRFONT # prev yr cfont 118,BROW,118,EROW,DBFONT,black # - cfont 120,BROW,127,EROW,DRFONT # % cfont 128,BROW,128,EROW,DFONT,black # - # header cerase LEFTCOL,1,MAXCOLS,4 cbox LEFTCOL,.1,RIGHTCOL,4,MBOXSIZE,HSHADE text 2,1.5,{trim(cut(1,1,10,""))},HFONT text 1,1.5,{trim(cut(18,1,92,""))},HBCFONT,14,cols=MAXCOLS text 1,1.5,{trim(cut(121,1,10,""))},HRFONT,cols=MAXRCOLS text 2,2.5,{trim(cut(1,2,10,""))},HFONT text 1,2.75,{trim(cut(1,3,MAXCOLS,""))},HBCFONT,12,cols=MAXCOLS text 1,3.75,{trim(cut(1,4,MAXCOLS,""))},HCFONT,cols=MAXCOLS # detail header line cerase 1,10,MAXCOLS,10 cbox LEFTCOL,6,MAXCOLS,9,1,DSHADE local BROW=7 local EROW=8 cfont 2,BROW,6,EROW,ICFONT,black,proper # acnt no cfont 7,BROW,37,EROW,IFONT,proper # desc # current period local BROW=8 local EROW=8 cbox 39,7.375,81,7.375 cfont 38,7,81,7,ICFONT,black cfont 38,BROW,49,EROW,IRFONT,black,proper # this yr cfont 52,BROW,57,EROW,IRFONT # % cerase 65,8,74,8 text 72,BROW,"Last Year",IRFONT # prev yr cfont 74,BROW,81,EROW,IRFONT # % # year to date cbox 85,7.375,127,7.375 cfont 84,7,127,7,ICFONT,black cfont 84,BROW,95,EROW,IRFONT,proper # this yr cfont 98,BROW,103,EROW,IRFONT # % cerase 111,8,120,8 text 118,BROW,"Last Year",IRFONT # prev yr cfont 120,BROW,127,EROW,IRFONT # % # special detail lines font "~ [A-Z]@5,11,7,MAXROWS",2,0,50,1,DBFONT,11 font "~ [A-Z]@6,11,8,MAXROWS",2,0,50,1,DBFONT,10 font "~ TOTAL@8,11,14,MAXROWS",2,0,27,1,IBFONT,10 box "~ TOTAL@8,11,14,MAXROWS",1,-.85,119,1.4,1,DSHADE erase "~ TOTAL@8,11,14,MAXROWS",0,-1,MAXCOLS,1 erase "~ TOTAL@8,11,14,MAXROWS",0,1,MAXCOLS,1 font "~ TOTAL@9,11,15,MAXROWS",2,0,27,1,IBFONT,10 box "~ TOTAL@9,11,15,MAXROWS",1,-.85,118,1.4,1,DSHADE erase "~ TOTAL@9,11,15,MAXROWS",0,-1,MAXCOLS,1 erase "~ TOTAL@9,11,15,MAXROWS",0,1,MAXCOLS,1 font "~ GROSS@9,11,15,MAXROWS",2,0,27,IBFONT,10 box "~ GROSS@9,11,15,MAXROWS",1,-.85,118,1.4,1,HSHADE font "~ PROFI@9,11,15,MAXROWS",2,0,27,1,IBFONT,10 box "~ PROFI@9,11,15,MAXROWS",1,-.85,118,1.4,1,HSHADE font "~ NET@9,11,15,MAXROWS",2,0,27,1,IBFONT,10 box "~ NET@9,11,15,MAXROWS",1,-.85,118,1.4,1,HSHADE font "~FEDERAL INCOME TAX EXPENSE@6,11,33,MAXROWS",0,0,26,1,DBFONT,black font "~STATE INCOME TAX EXPENSE@6,11,33,MAXROWS",0,0,26,1,DBFONT,black # unaudited font "UNAUDITED",0,0,9,1,HFONT [GL_TrialBalance] detect 0,3,"TRIAL BALANCE" detect 1,8,"GL" # set up document constants local MAXCOLS=131 # max cols to output local MAXRCOLS=130 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local MAX_COPIES=1 pcopies MAX_COPIES landscape dpi 600 # see global constant above GSON # graphical shading title "Trial Balance" # view in pdf properties cmove LEFTCOL,1,MAXCOLS,MAXROWS,2,1 # default detail line local BROW=1 local EROW=MAXCOLS cfont 2,BROW,14,EROW,DBFONT # acnt # cfont 16,BROW,51,EROW,DBFONT # desc cfont 55,BROW,67,EROW,DBRFONT # debit cfont 75,BROW,87,EROW,DBRFONT # credit cfont 98,BROW,110,EROW,DBRFONT # debit cfont 118,BROW,130,EROW,DBRFONT # credit # header cerase LEFTCOL,1,MAXCOLS,4 cbox LEFTCOL,.1,RIGHTCOL,4.5,MBOXSIZE,HSHADE text 2,3,{trim(get(1,1,10))},HFONT text 1,1.65,{trim(get(11,1,110))},HBCFONT,14,cols=MAXCOLS text 1,3,{trim(get(11,3,110))},HBCFONT,12,cols=MAXCOLS text 1,1.65,{trim(get(122,1,10))},HRFONT,cols=MAXRCOLS text 2,1.65,{trim(get(1,3,10))},HFONT text 1,3,{trim(get(1,2,10))},HRFONT,cols=MAXRCOLS text 1,4.15,{trim(get(11,4,110))},HCFONT,cols=MAXCOLS text 2,4.15,{trim(get(1,4,10))},HFONT # detail header line cerase 1,9,MAXCOLS,9 cbox LEFTCOL,5,MAXCOLS,9,1,DSHADE local BROW=8 local EROW=8 cfont 55,6,96,7,ICFONT,10 cfont 98,6,136,7,ICFONT,10 cfont 2,BROW,14,EROW,IFONT # acnt # cfont 16,BROW,51,EROW,IFONT # desc cfont 55,BROW,67,EROW,IRFONT # debit cfont 75,BROW,87,EROW,IRFONT # credit cfont 98,BROW,110,EROW,IRFONT # debit cfont 118,BROW,130,EROW,IRFONT # credit cmove 2,BROW,130,EROW,2,8.25 # totals erase " BALANCE@14,10,22,MAXROWS",0,-1,MAXCOLS,1 erase " BALANCE@14,10,22,MAXROWS",0,1,MAXCOLS,1 box " BALANCE@14,10,22,MAXROWS",1,-1,116,2,MBOXSIZE,HSHADE font " BALANCE@14,10,22,MAXROWS",2,0,15,1,IBFONT font "End of Report",0,0,13,1,HFONT [PO_PurchOrder8.5x11] detect 53,3,"~ [0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9] DATEMASK" detect 75,6,"~[0-9]" # page # detect 5,9,"~ [0-z]" # cust name # set up document constants local MAXCOLS=81 # max cols to output local MAXRCOLS=80 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local VENDOR_COPY=1 local FILE_COPY=2 local MAX_COPIES=2 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Purchase Order - 8.5 x 11" # view in pdf properties prejob { logocols=12,logorows=7 dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then copy_title$[VENDOR_COPY]="Vendor Copy" if MAX_COPIES>=2 then copy_title$[FILE_COPY]="File Copy" doc_title$="PURCHASE ORDER" merge "zMrg get watermark text" } prepage { xcol=0,xrow=0 merge "zMrg get company info" # add zip barcode xrow=12;xcols=40 #merge "zmrg get zip" } # shift down 1 for more room at top cmove LEFTCOL,1,RIGHTCOL,MAXROWS,1,3 # header section cerase 1,1,MAXCOLS,9 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=10:MBOXSIZE merge "zMrg Form Header" # Invoice block cbox 60,4.5,RIGHTCOL,9.5,1,ccols=72::ISHADE,crows=5.5 6.5 7.5 8.5 text 61,5,"PO Number",IFONT text 61,6,"PO Date",IFONT text 61,7,"Req'd Ship Date",IFONT text 61,8,"Location",IFONT text 61,9,"Page",IFONT text 73,5,{trim(get(54,3,8))},DBFONT text 73,6,{trim(get(65,3,10))},DBFONT text 73,7,{trim(get(54,6,10))},DBFONT text 73,8,{trim(get(66,6,6))},DBFONT text 73,9,{trim(get(75,6,3))},DBFONT # vendor address cmove 5,16,MAXRCOLS,19,6,16 cmove 42,16,MAXRCOLS,19,45,16 cbox LEFTCOL,10,RIGHTCOL,20,MBOXSIZE,ccols=8::ISHADE 40 47::ISHADE text 1,11,"Vendor",ICFONT,cols=8,fit cmove 6,11,39,19,9,11 cfont 9,11,42,19,DBLFONT # vend addr text 40,11,"Ship To",ICFONT,cols=8,fit cmove 45,11,MAXRCOLS,19,48,11 cfont 48,11,MAXRCOLS,19,DBFONT # ship to addr # zip bar #barcode 48,16,{shipzip$},900,12.0,2 # ribbon info cbox LEFTCOL,20,RIGHTCOL,23,MBOXSIZE,crows=21.5::ISHADE, ccols=21 40 59 text 1,21,"Ordered By",ICFONT,cols=20 text 22,21,"Ship Via",ICFONT,cols=18 text 41,21,"F.O.B.",ICFONT,cols=18 text 60,21,"Terms Description",ICFONT,cols=19 cfont 1,22,20,22,DBCFONT cfont 22,22,39,22,DBCFONT cfont 41,22,58,22,DBCFONT cfont 60,22,79,22,DBCFONT # line detail cbox LEFTCOL,23,RIGHTCOL,51,MBOXSIZE,crows=24.5::DSHADE,ccols=6 28 33 47 62 text 2,24,"Entry #",ICFONT,cols=4 text 7,24,"Item ID",IFONT text 28,24,"U/M",ICFONT,cols=6 text 35,24,"Unit Price",IRFONT,cols=12 text 49,24,"Ordered Quantity",IRFONT,cols=13 text 64,24,"Extension",IRFONT,cols=16 # default detail line local BROW=25 local EROW=50 cfont 2,BROW,5,EROW,DCFONT # line # cfont 7,BROW,26,EROW,DBFONT # item # cfont 28,BROW,33,EROW,DCFONT # uom cfont 35,BROW,46,EROW,DBRFONT # price cfont 49,BROW,61,EROW,DBRFONT # qty ord cfont 64,BROW,MAXRCOLS,EROW,DBRFONT # ext # move for shading cmove 1,23,80,48,1,24 # shade item lines shade "~[0-9][0-9][0-9]@2,23,4,50",-.5,0,80,1,DSHADE # description font " @2,23,2,50",5,0,54,1,DFONT # description # req date font "Req Date",0,0,19,1,DBRFONT # req date # watermark - large font with light shading WATERMARK 1,50.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # message area cbox LEFTCOL,51,RIGHTCOL,53,MBOXSIZE cfont 1,52,48,52,IFONT text 60,52,{trim(cut(50,50,17,""))+":"},IRFONT,cols=14 cfont 68,52,MAXRCOLS,52,DBRFONT # sub totals cbox LEFTCOL,53,RIGHTCOL,56,MBOXSIZE,crows=54.5::HSHADE,ccols=15 30 45 60 text 1,54,"Tax",IRFONT,cols=13 text 16,54,"Freight",IRFONT,cols=13 text 31,54,"Miscellaneous",IRFONT,cols=13 text 46,54,"Prepaid",IRFONT,cols=13 text 61,54,"Grand Total",IBRFONT,cols=19 cfont 1,55,13,55,DBRFONT cfont 16,55,28,55,DBRFONT cfont 31,55,43,55,DBRFONT,black cfont 46,55,58,55,DBRFONT,black cfont 61,55,MAXRCOLS,55,DBRFONT,fit # approval line cbox 55,60,RIGHTCOL,60 text 55.5,60.75,"Received by",HFONT cbox 55,64,MAXCOLS,64 text 55.5,64.75,"Authorized Signature",HFONT text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS [PO_PurchOrderLaser] detect 53,4,"~ [0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9] DATEMASK" detect 75,7,"~[0-9]" # page # detect 5,10,"~ [0-z]" # cust name # set up document constants local MAXCOLS=81 # max cols to output local MAXRCOLS=80 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local VENDOR_COPY=1 local FILE_COPY=2 local MAX_COPIES=2 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Purchase Order - laser" # view in pdf properties prejob { logocols=12,logorows=7 dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then copy_title$[VENDOR_COPY]="Vendor Copy" if MAX_COPIES>=2 then copy_title$[FILE_COPY]="File Copy" doc_title$="PURCHASE ORDER" merge "zMrg get watermark text" } prepage { xcol=0,xrow=0 merge "zMrg get company info" } # shift down 1 for more room at top cmove LEFTCOL,1,RIGHTCOL,MAXROWS,1,2 # default detail line local BROW=25 local EROW=50 cfont 2,BROW,5,EROW,DCFONT # line # cfont 7,BROW,26,EROW,DBFONT # item # cfont 28,BROW,33,EROW,DCFONT # uom cfont 35,BROW,46,EROW,DBRFONT # price cfont 49,BROW,61,EROW,DBRFONT # qty ord cfont 64,BROW,MAXRCOLS,EROW,DBRFONT # ext # header section cerase 1,1,MAXCOLS,9 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=10:MBOXSIZE merge "zMrg Form Header" # Invoice block cbox 60,4.5,RIGHTCOL,9.5,1,ccols=72::ISHADE,crows=5.5 6.5 7.5 8.5 text 61,5,"PO Number",IFONT text 61,6,"PO Date",IFONT text 61,7,"Req'd Ship Date",IFONT text 61,8,"Location",IFONT text 61,9,"Page",IFONT text 73,5,{trim(get(54,4,8))},DBFONT text 73,6,{trim(get(65,4,10))},DBFONT text 73,7,{trim(get(54,7,10))},DBFONT text 73,8,{trim(get(66,7,6))},DBFONT text 73,9,{trim(get(75,7,3))},DBFONT # vendor address cmove 5,16,MAXRCOLS,19,6,16 cmove 42,16,MAXRCOLS,19,45,16 cbox LEFTCOL,10,RIGHTCOL,20,MBOXSIZE,ccols=5::ISHADE 40 44::ISHADE text 2,11,"V\ne\nn\nd\no\nr",ICFONT,cols=3,fit cfont 6,11,39,19,DBLFONT # vend addr text 40,11,"S\nh\ni\np\n\nT\no",ICFONT,cols=5,fit cfont 45,11,MAXRCOLS,19,DBFONT # ship to addr # ribbon info cbox LEFTCOL,20,RIGHTCOL,23,MBOXSIZE,crows=21.5::ISHADE, ccols=21 40 59 text 1,21,"Ordered By",ICFONT,cols=20 text 22,21,"Ship Via",ICFONT,cols=18 text 41,21,"F.O.B.",ICFONT,cols=18 text 60,21,"Terms Description",ICFONT,cols=19 cfont 1,22,20,22,DBCFONT cfont 22,22,39,22,DBCFONT cfont 41,22,58,22,DBCFONT cfont 60,22,79,22,DBCFONT # line detail cbox LEFTCOL,23,RIGHTCOL,51,MBOXSIZE,crows=24.5::DSHADE,ccols=6 34 47 62 text 2,24,"Entry #",ICFONT,cols=4 text 7,24,"Item ID",IFONT text 28,24,"U/M",ICFONT,cols=6 text 35,24,"Unit Price",IRFONT,cols=12 text 49,24,"Ordered Quantity",IRFONT,cols=13 text 64,24,"Extension",IRFONT,cols=16 # description font " @2,24,2,50",5,0,54,1,DFONT # description #shade lines shade "~[0-9][0-9][0-9]@2,25,4,50",-.5,0,80,1,DSHADE # shade lines # req date font "Req Date",0,0,19,1,DBRFONT # req date # recd font "Recd",0,0,6,1,DFONT,BLACK font "Recd",7,0,13,1,DBRFONT # bk ord font "Bk Ord",0,0,6,1,DFONT,BLACK font "Bk Ord",7,0,13,1,DBRFONT # watermark - large font with light shading WATERMARK 1,50.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # message area cbox LEFTCOL,51,RIGHTCOL,53,MBOXSIZE cfont 1,52,48,52,IFONT cfont 50,52,60,52,DBRFONT cfont 63,52,MAXRCOLS,52,DBRFONT # sub totals cbox LEFTCOL,53,RIGHTCOL,56,MBOXSIZE,crows=54.5::HSHADE,ccols=15 30 45 60 text 1,54,"Tax",HRFONT,cols=13 text 16,54,"Freight",HRFONT,cols=13 text 31,54,"Miscellaneous",HRFONT,cols=13 text 46,54,"Prepaid",HRFONT,cols=13 text 61,54,"Grand Total",HBRFONT,cols=19 cfont 1,55,13,55,DBRFONT cfont 16,55,28,55,DBRFONT cfont 31,55,43,55,DBRFONT,black cfont 46,55,58,55,DBRFONT,black cfont 61,55,MAXRCOLS,55,DBRFONT,fit # approval line cbox 55,60,RIGHTCOL,60 text 55.5,60.75,"Received by",HFONT cbox 55,64,MAXCOLS,64 text 55.5,64.75,"Authorized Signature",HFONT text 1,{MAXROWS+.5},{copy_title$[copy]},IBCFONT,cols=MAXCOLS [PO_PurchOrderPlain] detect 0,1,"Purchase Order" # set up document constants local MAXCOLS=113 # max cols to output local MAXRCOLS=112 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows page MAXROWS # no form feeds local VENDOR_COPY=1 local FILE_COPY=2 local MAX_COPIES=2 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Purchase Order - plain" # view in pdf properties prejob { logocols=14,logorows=6 dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then : copy_title$[VENDOR_COPY]="Vendor Copy" endif if MAX_COPIES>=2 then : copy_title$[FILE_COPY]="File Copy" endif doc_title$="PURCHASE ORDER" merge "zMrg get watermark text" } prepage { xcol=6,xrow=1 merge "zMrg get company info" # add zip barcode xrow=17;xcols=40 #merge "zmrg get zip" # continued? cont$="",sub_line=52 for i=52 to MAXROWS x=pos("(continued"=text$[i]) if x then : cont$="Continued" sub_line=55 x$=set(x,i,30,"") break endif next i } # shift over 1 for more room on left cmove LEFTCOL,1,RIGHTCOL,MAXROWS,2,1 # default detail line cerase LEFTCOL,22,MAXCOLS,22 cerase LEFTCOL,24,MAXCOLS,24 cbox LEFTCOL,22,RIGHTCOL,{sub_line},MBOXSIZE,crows=24::DSHADE, ccols=6 50 62 68 81 95 local BROW=23 local EROW=23 cfont 2,BROW,5,EROW,ICFONT # line # cfont 7,BROW,49,EROW,ILFONT # item # cfont 51,BROW,61,EROW,IRFONT # price cfont 62,BROW,68,EROW,ICFONT # units cfont 69,BROW,80,EROW,IRFONT # qty ord cfont 82,BROW,94,EROW,IRFONT # qty rcvd cfont 96,BROW,MAXRCOLS,EROW,IRFONT # b/o local BROW=25 local EROW=51 cfont 2,BROW,5,EROW,DLFONT # line # cfont 7,BROW,41,EROW,DBFONT # item # cfont 42,BROW,50,EROW,DBRFONT # req date cfont 51,BROW,61,EROW,DBRFONT # price cfont 62,BROW,67,EROW,DRFONT # units cfont 69,BROW,80,EROW,DBRFONT # qty ord cfont 82,BROW,94,EROW,DBRFONT # qty rcvd cfont 96,BROW,MAXRCOLS,EROW,DBRFONT # b/o # header section cerase 1,1,MAXCOLS,9 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=9:MBOXSIZE merge "zMrg Form Header" # PO block cbox 85,5.5,MAXCOLS,8.5,1,ccols=101::ISHADE,crows=6.5 7.5 text 86,6,"PO Number",IFONT text 86,7,"Page",IFONT text 86,8,"Req'd Ship Date",IFONT text 102,6,{trim(get(69,4,10))},DBFONT text 102,7,{trim(get(83,4,10))},DBFONT text 102,8,{trim(get(69,7,14))},DBFONT # ribbon info cerase LEFTCOL,12,RIGHTCOL,12 cbox LEFTCOL,9,RIGHTCOL,12,MBOXSIZE,crows=10.5::ISHADE, ccols=12 33 44 69 cfont 2,10,11,10,ICFONT cfont 13,10,32,10,ICFONT cfont 34,10,43,10,ICFONT cfont 45,10,67,10,ICFONT cfont 69,10,MAXCOLS,10,ICFONT cfont 2,11,11,11,DBCFONT cfont 13,11,32,11,DBCFONT cfont 34,11,43,11,DBCFONT cfont 45,11,67,11,DBCFONT cfont 69,11,MAXRCOLS,11,DBCFONT # vendor address cmove 12,20,MAXRCOLS,21,13,20 cmove 49,20,MAXRCOLS,21,62,20 cbox LEFTCOL,12,MAXCOLS,22,MBOXSIZE,ccols=12::ISHADE 50 61::ISHADE cerase 3,13,10,21,ICFONT cfont 13,13,49,21,DBFONT # vend addr cerase 51,13,60,21,ICFONT cfont 62,13,MAXRCOLS,21,DBFONT # ship to addr text 2,14, "Vendor",ICFONT, cols=10 text 51,14, "Ship \nto",ICFONT, cols =10 # zip bar #barcode 62,18,{shipzip$},900,12.0,2 # watermark - large font with light shading WATERMARK 1,51.25,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # sub totals cerase LEFTCOL,55,RIGHTCOL,55 cbox "Subtotal@1,53",-6,-1,RIGHTCOL,55,MBOXSIZE,crows=53.5::HSHADE box "Subtotal@1,53",9,-1,1,3 box "Tax@1,53",4,-1,1,3 box "Freight@1,53",8,-1,1,3 box "Misc.@1,53",6,-1,1,3 box "Prepaid@1,53",8,-1,1,3 #box "Total@1,53",6,-1,1,3 font "Subtotal@1,53",0,0,9,1,IRFONT font "Tax@1,53",0,0,4,1,IRFONT font "Freight@1,53",0,0,8,1,IRFONT font "Misc.@1,53",0,0,6,1,IRFONT,black font "Prepaid@1,53",0,0,8,1,IRFONT,black font "Total@1,53",0,0,27,1,IRFONT,black font "Subtotal@1,53",-4,1,13,1,DBRFONT font "Tax@1,53",-10,1,14,1,DBRFONT font "Freight@1,53",-6,1,14,1,DBRFONT font "Misc.@1,53",-8,1,14,1,DBRFONT font "Prepaid@1,53",-6,1,14,1,DBRFONT font "Total@1,53",-9,1,36,1,DBRFONT # message area cbox LEFTCOL,55,MAXCOLS,MAXROWS,MBOXSIZE cfont 2,56,10,56,IFONT cfont 12,56,60,56,IFONT cfont 2,57,60,65,IFONT # shade lines shade "~[0-9][0-9][0-9]@2,25,4,51",-.5,0,112,1,DSHADE # description font " @2,25,2,51",5,0,70,1,DLFONT # approval line cerase 61,56,RIGHTCOL,65 cbox 65,58,MAXRCOLS,58 text 65.5,58.75,"Received by",HCFONT,cols=45 cbox 65,62,MAXRCOLS,62 text 65.5,62.75,"Authorized Signature",HCFONT,cols=45 text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS text 1,{MAXROWS+.5},{cont$},DBRFONT,cols=MAXRCOLS [PO_PurchOrderStd] detect 68,1,"~ [0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]" detect 85,1,"~[0-9]" # page # detect 68,4,"~ DATEMASK" # cust name # set up document constants local MAXCOLS=109 # max cols to output local MAXRCOLS=108 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local VENDOR_COPY=1 local FILE_COPY=2 local MAX_COPIES=2 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Purchase Order - Standard" # view in pdf properties prejob { logocols=14,logorows=6 dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then copy_title$[VENDOR_COPY]="Vendor Copy" if MAX_COPIES>=2 then copy_title$[FILE_COPY]="File Copy" doc_title$="PURCHASE ORDER" merge "zMrg get watermark text" } prepage { xcol=0,xrow=0 merge "zMrg get company info" # add zip barcode xrow=14;xcols=40 #merge "zmrg get zip" # continued? cont$="",sub_line=52 for i=52 to MAXROWS x=pos("(continued"=text$[i]) if x then : cont$="Continued" sub_line=55 x$=set(x,i,30,"") break endif next i } # shift down 1 for more room at top cmove LEFTCOL,1,RIGHTCOL,MAXROWS,2,4 # default detail line cerase LEFTCOL,22,MAXCOLS,22 cerase LEFTCOL,24,MAXCOLS,24 cbox LEFTCOL,22,RIGHTCOL,{sub_line},MBOXSIZE,crows=24::DSHADE, ccols=5.5 50 61 68 81 95 local BROW=22 local EROW=50 cfont 2,BROW,4,EROW,DCFONT # line # cfont 6,BROW,49,EROW,DBFONT # item # cfont 51,BROW,60,EROW,DBRFONT # price cfont 62,BROW,67,EROW,DCFONT # units cfont 69,BROW,80,EROW,DBRFONT # qty ord cfont 82,BROW,94,EROW,DBRFONT # qty rcvd cfont 96,BROW,MAXRCOLS,EROW,DBRFONT # b/o # line detail text 2,23,"Line",ICFONT,cols=3 text 7,23,"Item/Description",IFONT text 51,23,"Unit Price",IRFONT,cols=10 text 62,23,"Units",IRFONT,cols=5 text 69,23,"Ordered",IRFONT,cols=12 text 82,23,"Received",IRFONT,cols=13 text 96,23,"Backordered",IRFONT,cols=13 # header section cerase 1,1,MAXCOLS,9 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=9:MBOXSIZE merge "zMrg Form Header" # PO block cbox 84,5.5,MAXCOLS,8.5,1,ccols=99::ISHADE,crows=6.5 7.5 text 85,6,"PO Number",IFONT text 85,7,"Page",IFONT text 85,8,"Req'd Ship Date",IFONT text 100,6,{trim(get(69,1,8))},DBFONT text 100,7,{trim(get(83,1,3))},DBFONT text 100,8,{trim(get(69,4,10))},DBFONT # ribbon info cerase LEFTCOL,12,RIGHTCOL,12 cbox LEFTCOL,9,RIGHTCOL,12,MBOXSIZE,crows=10.5::ISHADE, ccols=12 33 44 69 text 2,10,"Ord. Date",ICFONT,cols=9 text 13,10,"Ordered By",ICFONT,cols=19 text 34,10,"Terms",ICFONT,cols=9 text 45,10,"F.O.B.",ICFONT,cols=22 text 69,10,"Ship Via",ICFONT,cols=40 cfont 2,11,11,11,DBCFONT cfont 13,11,32,11,DBCFONT cfont 34,11,43,11,DBCFONT cfont 45,11,67,11,DBCFONT cfont 69,11,MAXRCOLS,11,DBCFONT # vendor address cmove 12,20,MAXRCOLS,21,13,20 cmove 49,20,MAXRCOLS,21,62,20 cmove 13,13,49,21,22,13 cbox LEFTCOL,12,MAXCOLS,22,MBOXSIZE,ccols=10::ISHADE 50 59::ISHADE text 6,14,"Vendor",ICFONT cmove 13,13,49,21,11.5,13 cfont 11.5,13,47,21,DBLFONT # vend addr text 55,14,"Ship To",ICFONT cmove 62,13,MAXRCOLS,21,60.5,13 cfont 60.5,13,MAXRCOLS,21,DBFONT # ship to addr # zip bar #barcode 60.5,18,{shipzip$},900,12.0,2 # line detail # description font " @2,24,2,51",5,0,77,1,DFONT # description # watermark - large font with light shading WATERMARK 1,51.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # shade lines shade "~[0-9][0-9][0-9]@2,24,4,51",-.5,0,108,1,DSHADE # sub totals cbox "Subtotal@1,53",-6,-.5,RIGHTCOL,55.5,MBOXSIZE,crows=54.5::HSHADE box "Subtotal@1,53",9,-.5,1,2 box "Tax@1,53",4,-.5,1,2 box "Freight@1,53",8,-.5,1,2 box "Misc.@1,53",6,-.5,1,2 box "Prepaid@1,53",13,-.5,1,2 font "Subtotal@1,53",0,0,9,1,IRFONT font "Tax@1,53",0,0,4,1,IRFONT font "Freight@1,53",0,0,8,1,IRFONT font "Misc.@1,53",0,0,6,1,IRFONT,black font "Prepaid@1,53",0,0,13,1,IRFONT,black font "Total@1,53",0,0,23,1,IRFONT,black font "Subtotal@1,53",-4,1,13,1,DBRFONT font "Tax@1,53",-10,1,14,1,DBRFONT font "Freight@1,53",-6,1,14,1,DBRFONT font "Misc.@1,53",-8,1,14,1,DBRFONT font "Prepaid@1,53",-6,1,19,1,DBRFONT font "Total@1,53",-3,1,26,1,DBRFONT # message area cbox LEFTCOL,55.5,MAXCOLS,MAXROWS,MBOXSIZE cfont 2,56,10,56,IFONT cfont 12,56,60,56,IFONT cfont 2,57,60,65,IFONT # approval line cerase 61,56,RIGHTCOL,65 cbox 65,58,MAXRCOLS,58 text 65.5,58.75,"Received by",HCFONT,cols=45 cbox 65,62,MAXRCOLS,62 text 65.5,62.75,"Authorized Signature",HCFONT,cols=45 text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS text 1,{MAXROWS+.5},{cont$},DBRFONT,cols=MAXRCOLS [PR_CheckBlank] detect 0,10,"~ DATEMASK" detect 0,24,"~ [0-9][0-9]/[0-9][0-9]/[0-9][0-9] [0-9][0-9]/[0-9][0-9]/[0-9][0-9] " detect 0,1,"!D I R E C T D E P O S I T V O U C H E R" # set up document constants local MAXCOLS=81 local MAXRCOLS=80 local MAXROWS=66 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line cols MAXCOLS rows MAXROWS page 42 # copy 2 is for summary local MAX_COPIES=2 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "PR Check - blank" # view in pdf properties prejob { logocols=10,logorows=5 } prepage { dtype$=get(1,1,MAXCOLS,"Y") if dtype$="" then : # check checkno$=get(57,10,8,"Y") docid$=checkno$ docdate$=get(46,10,8,"Y") chkamt$=get(65,10,15,"Y") chktextamt$=get(1,11,MAXCOLS,"Y") emp$=mget(6,14,40,4,"Y","Y") else # summary docid$=get(36,4,10,"Y") docdate$=get(36,3,10,"Y") endif for row=22 to 42 text$[row+21]=text$[row] next row } precopy { # Summary? if copy=1 and dtype$<>"" then skip=1 if copy=2 and dtype$="" then skip=1 if copy=2 and not(skip) then : docdate$=get(36,3,8,"Y",1) endif } # make space on left cmove 1,1,MAXCOLS,MAXROWS,2,1 if copy 1 # make room on left cmove 1,1,MAXCOLS,MAXROW,2,1 # Check cerase 1,1,MAXCOLS,20 LOGO_IMAGE 1,1,10,5,"COMP_LOGO" cbox LEFTCOL,1,RIGHTCOL,17.75,MBOXSIZE text 15,2.25,"COMP_NAME",HBFONT,14 text 15,3.35,"COMP_ADDR1",HFONT,12 text 15,4.35,"COMP_ADDR2",HFONT,12 text 15,5.35,"COMP_ADDR3",HFONT,12 text 49,2.25,"PR_BANK_NAME",DBFONT text 49,3.05,"PR_BANK_ADDR1",DFONT text 49,3.85,"PR_BANK_ADDR2",DFONT text 70,3.35,"PR_ROUTING",DBFONT # rtg # cbox 44,5.5,RIGHTCOL,7.5,1,crows=6.5::100,ccols=52 63 text 45,6,"Check #",ICFONT,10,cols=7,shade=0 text 45,7,{checkno$},DBCFONT,11,cols=7 text 53,6,"Date",ICFONT,10,cols=10,shade=0 text 53,7,{docdate$},DBCFONT,11,cols=10 text 64,6,"Amount",IRFONT,10,cols=17,shade=0 text 64,7,{chkamt$},DBRFONT,11,cols=17 text 2,10,"Pay",IFONT,14 text 7,10,{chktextamt$},DBFONT,italic,11,fit text 2,13,"Pay",IFONT text 2,14,"to the",IFONT text 2,15,"Order",IFONT text 2,16,"of",IFONT text 7,13,{emp$},DBFONT,11 SIGNATURE_IMAGE 50,15,0,0,"SIGNATURE" box 50,16.25,30,1,3 text 50,14.5,"Check Void After 180 Days",ICFONT,cols=30 text 50,17,"Authorized Signature",ICFONT,cols=30 PR_MICR 15,18.5,"PR_MICR_ACCOUNTNO",{trim(get(64,22,7))} # top stub - employee's cerase 1,22,MAXCOLS,22 cbox LEFTCOL,21,MAXCOLS,21 text 15,22,"COMP_NAME",HBFONT,12 cbox LEFTCOL,22.5,MAXCOLS,24.5,MBOXSIZE,crows=23.5::DSHADE,ccols=15 33 45 54 63 local SROW=23 cfont 2,SROW,14,SROW,ICFONT,proper cfont 16,SROW,32,SROW,ICFONT,proper cfont 34,SROW,43,SROW,ICFONT,proper cfont 45,SROW,53,SROW,ICFONT,proper cfont 55,SROW,62,SROW,ICFONT,proper cfont 64,SROW,MAXRCOLS,SROW,ICFONT,proper local SROW=24 cfont 2,SROW,14,SROW,DBCFONT cfont 16,SROW,32,SROW,DBCFONT cfont 34,SROW,43,SROW,DBCFONT cfont 45,SROW,53,SROW,DBCFONT cfont 55,SROW,62,SROW,DBCFONT cfont 64,SROW,MAXRCOLS,SROW,DBCFONT cmove LEFTCOL,26,MAXCOLS,38,LEFTCOL,25 cbox LEFTCOL,24.5,MAXCOLS,38.5,MBOXSIZE,crows=25.5::DSHADE,ccols=14 24 34 45 60 70 local SROW=25 cfont 2,SROW,13,SROW,IFONT,proper cfont 15,SROW,23,SROW,IRFONT,black,proper cfont 25,SROW,33,SROW,IRFONT,proper cfont 35,SROW,44,SROW,IRFONT,proper cfont 46,SROW,59,SROW,ILFONT,proper cfont 61,SROW,69,SROW,IRFONT,proper cfont 71,SROW,MAXRCOLS,SROW,IRFONT,proper local SROW=26 local EROW=35 cfont 2,SROW,13,EROW,DFONT cfont 15,SROW,23,EROW,DBRFONT,black cfont 25,SROW,33,EROW,DBRFONT cfont 35,SROW,44,EROW,DBRFONT local EROW=38 cfont 46,SROW,59,EROW,DLFONT cfont 61,SROW,69,EROW,DBRFONT cfont 71,SROW,MAXRCOLS,EROW,DBRFONT text 2,36,{mget(1,36,13,2,"Y","Y")},IBFONT text 15,36,{mget(17,36,9,2,"Y","Y")},DBRFONT,cols=9 cerase 1,36,14,37 cerase 16,36,26,37 cmove LEFTCOL,40,MAXCOLS,41,LEFTCOL,39 cbox LEFTCOL,38.5,MAXCOLS,40.5,MBOXSIZE,crows=39.5::100,ccols=14 25 37 48 60 71 local SROW=39 cfont 2,SROW,13,SROW,IFONT,shade=0 cfont 15,SROW,24,SROW,IRFONT,shade=0 cfont 26,SROW,36,SROW,IRFONT,shade=0 cfont 38,SROW,47,SROW,IRFONT,shade=0 cfont 49,SROW,59,SROW,IRFONT,shade=0 cerase 61,SROW,MAXCOLS,SROW text 61,SROW,"YTD Ded",IRFONT,shade=0,cols=10 text 72,SROW,"YTD Net Pay",IRFONT,shade=0,cols=9 local SROW=40 cfont 2,SROW,13,SROW,DBFONT cfont 15,SROW,24,SROW,DBRFONT cfont 26,SROW,36,SROW,DBRFONT cfont 38,SROW,47,SROW,DBRFONT cfont 49,SROW,59,SROW,DBRFONT cfont 61,SROW,70,SROW,DBRFONT cfont 72,SROW,MAXRCOLS,SROW,DBRFONT # Bottom stub - employer's cerase 1,43,MAXCOLS,43 cbox LEFTCOL,42,MAXCOLS,42 text 15,43,"COMP_NAME",HBFONT,12 cbox LEFTCOL,43.5,MAXCOLS,45.5,MBOXSIZE,crows=44.5::DSHADE,ccols=15 33 45 54 63 local SROW=44 cfont 2,SROW,14,SROW,ICFONT,proper cfont 16,SROW,32,SROW,ICFONT,proper cfont 34,SROW,43,SROW,ICFONT,proper cfont 45,SROW,53,SROW,ICFONT,proper cfont 55,SROW,62,SROW,ICFONT,proper cfont 64,SROW,MAXRCOLS,SROW,ICFONT,proper local SROW=45 cfont 2,SROW,14,SROW,DBCFONT cfont 16,SROW,32,SROW,DBCFONT cfont 34,SROW,43,SROW,DBCFONT cfont 45,SROW,53,SROW,DBCFONT cfont 55,SROW,62,SROW,DBCFONT cfont 64,SROW,MAXRCOLS,SROW,DBCFONT cmove LEFTCOL,47,MAXCOLS,59,LEFTCOL,46 cbox LEFTCOL,45.5,MAXCOLS,59.5,MBOXSIZE,crows=46.5::DSHADE,ccols=14 24 34 45 60 70 local SROW=46 cfont 2,SROW,13,SROW,IFONT,proper cfont 15,SROW,23,SROW,IRFONT,black,proper cfont 25,SROW,33,SROW,IRFONT,proper cfont 35,SROW,44,SROW,IRFONT,proper cfont 46,SROW,59,SROW,ILFONT,proper cfont 61,SROW,69,SROW,IRFONT,proper cfont 71,SROW,MAXRCOLS,SROW,IRFONT,proper local SROW=47 local EROW=56 cfont 2,SROW,13,EROW,DFONT cfont 15,SROW,23,EROW,DBRFONT,black cfont 25,SROW,33,EROW,DBRFONT cfont 35,SROW,44,EROW,DBRFONT local EROW=59 cfont 46,SROW,59,EROW,DLFONT cfont 61,SROW,69,EROW,DBRFONT cfont 71,SROW,MAXRCOLS,EROW,DBRFONT text 2,57,{mget(1,57,13,2,"Y","Y")},IBFONT text 15,57,{mget(17,57,9,2,"Y","Y")},DBRFONT,cols=9 cerase 1,57,14,58 cerase 16,57,26,58 cmove LEFTCOL,61,MAXCOLS,62,LEFTCOL,60 cbox LEFTCOL,59.5,MAXCOLS,61.5,MBOXSIZE,crows=60.5::100,ccols=14 25 37 48 60 71 local SROW=60 cfont 2,SROW,13,SROW,IFONT,shade=0 cfont 15,SROW,24,SROW,IRFONT,shade=0 cfont 26,SROW,36,SROW,IRFONT,shade=0 cfont 38,SROW,47,SROW,IRFONT,shade=0 cfont 49,SROW,59,SROW,IRFONT,shade=0 cerase 61,SROW,MAXCOLS,SROW text 61,SROW,"YTD Ded",IRFONT,shade=0,cols=10 text 72,SROW,"YTD Net Pay",IRFONT,shade=0,cols=9 local SROW=61 cfont 2,SROW,13,SROW,DBFONT cfont 15,SROW,24,SROW,DBRFONT cfont 26,SROW,36,SROW,DBRFONT cfont 38,SROW,47,SROW,DBRFONT cfont 49,SROW,59,SROW,DBRFONT cfont 61,SROW,70,SROW,DBRFONT cfont 72,SROW,MAXRCOLS,SROW,DBRFONT end if # summary copy if copy 2 notext # title text 1,2,"Payroll Check Summary",HBCFONT,cols=MAXRCOLS,14 # summary text 25,6,{mget(14,1,21,7,"Y","Y")},HBFONT text 58,6,{mget(36,1,13,7,"Y","Y")},DBRFONT,11 # end of report text 2,15,{get(1,10,13,"Y")},HBCFONT,cols=MAXRCOLS end if [PR_CheckLaser] detect 0,8,"~ DATEMASK" detect 0,22,"~ [0-9][0-9]/[0-9][0-9]/[0-9][0-9] [0-9][0-9]/[0-9][0-9]/[0-9][0-9] " detect 0,1,"!D I R E C T D E P O S I T V O U C H E R" # set up document constants local MAXCOLS=81 local MAXRCOLS=80 local MAXROWS=66 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line cols MAXCOLS rows MAXROWS # copy 2 is for summary local MAX_COPIES=2 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "PR Check - laser" # view in pdf properties prejob { logocols=10,logorows=5 } prepage { dtype$=get(1,1,MAXCOLS,"Y") if dtype$="" then : # check docdate$=get(53,8,8,"Y") else # summary docdate$=get(36,3,10,"Y") endif } precopy { # Summary? xtype$=trim(get(1,1,20)) if copy=1 and xtype$<>"" then skip=1 if copy=2 and xtype$="" then skip=1 if copy=2 and not(skip) then : docdate$=get(36,3,10,"Y",1) endif } # make space on left cmove 1,1,MAXCOLS,MAXROWS,2,1 if copy 1 # first adjust format to standard cmove 1,20,MAXCOLS,60,1,22 cerase 1,1,30,6 # Check LOGO_IMAGE 1,1,10,5,"COMP_LOGO" cbox LEFTCOL,1,RIGHTCOL,17.75,MBOXSIZE text 15,2.25,"COMP_NAME",HBFONT,14 text 15,3.35,"COMP_ADDR1",HFONT,12 text 15,4.35,"COMP_ADDR2",HFONT,12 text 15,5.35,"COMP_ADDR3",HFONT,12 text 49,2.25,"PR_BANK_NAME",DBFONT text 49,3.05,"PR_BANK_ADDR1",DFONT text 49,3.85,"PR_BANK_ADDR2",DFONT text 70,3.35,"PR_ROUTING",DBFONT # rtg # cmove 53,8,MAXCOLS,8,53,7 cbox 44,5.5,RIGHTCOL,7.5,1,crows=6.5::100,ccols=52 63 text 45,6,"Check #",ICFONT,10,cols=7,shade=0 text 45,7,{trim(get(64,22,7))},DBCFONT,11,cols=7 text 53,6,"Date",ICFONT,10,cols=10,shade=0 cfont 53,7,62,7,DBCFONT,11 text 64,6,"Amount",IRFONT,10,cols=17,shade=0 cfont 64,7,MAXRCOLS,7,DBRFONT,11 text 2,10,"Pay",IFONT,14 text 7,10,{trim(cut(5,9,80,""))},DBFONT,italic,11,fit text 2,13,"Pay",IFONT text 2,14,"to the",IFONT text 2,15,"Order",IFONT text 2,16,"of",IFONT cmove 6,11,47,14,6,13 cfont 7,13,51,16,DBFONT,11 SIGNATURE_IMAGE 50,15,0,0,"SIGNATURE" box 50,16.25,30,1,3 text 50,14.5,"Check Void After 180 Days",ICFONT,cols=30 text 50,17,"Authorized Signature",ICFONT,cols=30 PR_MICR 15,18.5,"PR_MICR_ACCOUNTNO",{trim(get(64,22,7))} # top stub - employee's cerase 1,22,30,22 cbox LEFTCOL,21,MAXCOLS,21 text 15,22,"COMP_NAME",HBFONT,12 cbox LEFTCOL,22.5,MAXCOLS,24.5,MBOXSIZE,crows=23.5::DSHADE, ccols=15 33 45 54 64 cfont 2,23,14,23,ICFONT,proper cfont 16,23,32,23,ICFONT,proper cfont 34,23,44,23,ICFONT,proper cfont 46,23,53,23,ICFONT,proper cfont 55,23,63,23,ICFONT,proper cfont 65,23,MAXRCOLS,23,ICFONT,proper cfont 2,24,14,24,DBCFONT cfont 16,24,32,24,DBCFONT cfont 34,24,44,24,DBCFONT cfont 46,24,53,24,DBCFONT cfont 55,24,63,24,DBCFONT cfont 65,24,MAXRCOLS,24,DBCFONT cbox LEFTCOL,24.5,MAXCOLS,38.5,MBOXSIZE,crows=25.5::DSHADE, ccols=14 23 34 47 60 70 cfont 2,25,13,25,IFONT,proper cfont 14,25,22,25,IRFONT,black,proper cfont 24,25,33,25,IRFONT,proper cfont 35,25,46,25,IRFONT,proper cfont 48,25,59,25,IFONT,proper cfont 61,25,69,25,IRFONT,proper cfont 71,25,MAXRCOLS,25,IRFONT,proper cfont 2,26,13,35,DFONT cfont 14,26,22,35,DBRFONT,black cfont 24,26,33,35,DBRFONT cfont 35,26,46,35,DBRFONT cfont 48,26,59,38,DFONT cfont 61,26,69,38,DBRFONT cfont 71,26,MAXRCOLS,38,DBRFONT text 2,36,{mcut(1,34,15,2,"","Y","Y")},IBFONT text 14,36,{mcut(17,34,9,2,"","Y","Y")},DBRFONT,cols=9 cbox LEFTCOL,38.5,MAXCOLS,40.5,MBOXSIZE,crows=39.5::100, ccols=13 25 37 48 60 71 cfont 2,39,12,39,IFONT,shade=0 cfont 14,39,24,39,IRFONT,shade=0 cfont 26,39,36,39,IRFONT,shade=0 cfont 38,39,47,39,IRFONT,shade=0 cfont 49,39,59,39,IRFONT,shade=0 cerase 61,39,MAXCOLS,39 text 61,39,"YTD Ded",IRFONT,shade=0,cols=10 text 72,39,"YTD Net Pay",IRFONT,shade=0,cols=9 cfont 2,40,12,40,DBFONT cfont 14,40,24,40,DBRFONT cfont 26,40,36,40,DBRFONT cfont 38,40,47,40,DBRFONT cfont 49,40,59,40,DBRFONT cfont 61,40,70,40,DBRFONT cfont 72,40,MAXRCOLS,40,DBRFONT # Bottom stub - employer's cerase 1,43,30,43 cbox LEFTCOL,42,MAXCOLS,42 text 15,43,"COMP_NAME",HBFONT,12 cbox LEFTCOL,43.5,MAXCOLS,45.5,MBOXSIZE,crows=44.5::DSHADE, ccols=15 33 45 54 64 cfont 2,44,14,44,ICFONT,proper cfont 16,44,32,44,ICFONT,proper cfont 34,44,44,44,ICFONT,proper cfont 46,44,53,44,ICFONT,proper cfont 55,44,63,44,ICFONT,proper cfont 65,44,MAXRCOLS,44,ICFONT,proper cfont 2,45,14,45,DBCFONT cfont 16,45,32,45,DBCFONT cfont 34,45,44,45,DBCFONT cfont 46,45,53,45,DBCFONT cfont 55,45,63,45,DBCFONT cfont 65,45,MAXRCOLS,45,DBCFONT cbox LEFTCOL,45.5,MAXCOLS,59.5,MBOXSIZE,crows=46.5::DSHADE, ccols=14 23 34 47 60 70 cfont 2,46,13,46,IFONT,proper cfont 14,46,22,46,IRFONT,black,proper cfont 24,46,33,46,IRFONT,proper cfont 35,46,46,46,IRFONT,proper cfont 48,46,59,46,IFONT,proper cfont 61,46,69,46,IRFONT,proper cfont 71,46,MAXRCOLS,46,IRFONT,proper cfont 2,47,13,56,DFONT cfont 14,47,22,56,DBRFONT,black cfont 24,47,33,56,DBRFONT cfont 35,47,46,56,DBRFONT cfont 48,47,59,59,DFONT cfont 61,47,69,59,DBRFONT cfont 71,47,MAXRCOLS,59,DBRFONT text 2,57,{mcut(1,55,15,2,"","Y","Y")},IBFONT text 14,57,{mcut(17,55,9,2,"","Y","Y")},DBRFONT,cols=9 cbox LEFTCOL,59.5,MAXCOLS,61.5,MBOXSIZE,crows=60.5::100, ccols=13 25 37 48 60 71 cfont 2,60,12,60,IFONT,shade=0 cfont 14,60,24,60,IRFONT,shade=0 cfont 26,60,36,60,IRFONT,shade=0 cfont 38,60,47,60,IRFONT,shade=0 cfont 49,60,59,60,IRFONT,shade=0 cerase 61,60,MAXCOLS,60 text 61,60,"YTD Ded",IRFONT,shade=0,cols=10 text 72,60,"YTD Net Pay",IRFONT,shade=0,cols=9 cfont 2,61,12,61,DBFONT cfont 14,61,24,61,DBRFONT cfont 26,61,36,61,DBRFONT cfont 38,61,47,61,DBRFONT cfont 49,61,59,61,DBRFONT cfont 61,61,70,61,DBRFONT cfont 72,61,MAXRCOLS,61,DBRFONT end if # summary copy if copy 2 # title text 1,2,"Payroll Check Summary",HBCFONT,cols=MAXRCOLS,14 # summary text 25,6,{mcut(14,1,21,7,"","Y","Y")},HBFONT text 58,6,{mcut(36,1,13,7,"","Y","Y")},DBRFONT,11 # end of report text 2,15,{cut(1,10,13,"")},HBCFONT,cols=MAXRCOLS end if [PR_CheckPreprinted] detect 0,27,"~ DATEMASK" detect 0,2,"~ [0-9][0-9]/[0-9][0-9]/[0-9][0-9] [0-9][0-9]/[0-9][0-9]/[0-9][0-9] " detect 0,1,"!D I R E C T D E P O S I T V O U C H E R" # set up document constants local MAXCOLS=81 local MAXRCOLS=80 local MAXROWS=66 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line cols MAXCOLS rows MAXROWS page 42 # copy 2 is for summary local MAX_COPIES=2 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "PR Check - preprinted" # view in pdf properties prejob { logocols=10,logorows=5 } prepage { # mje 082307 dtype$=get(1,1,MAXCOLS,"Y") # note, opposite of other 2 check formats if dtype$<>"" then : # check docdate$=get(58,27,8,"Y") else # summary docid$=get(36,5,10,"Y") docdate$=get(36,4,10,"Y") endif for row=1 to 21 text$[row+40]=text$[row] next row } precopy { # Summary? if copy=1 and dtype$="" then skip=1 if copy=2 and dtype$<>"" then skip=1 if copy=2 and not(skip) then : docdate$=get(36,3,10,"Y",1) endif } # make space on left cmove 1,1,MAXCOLS,MAXROWS,2,2 if copy 1 cerase 1,22,30,27 # Check LOGO_IMAGE 1,22,10,5,"COMP_LOGO" cbox LEFTCOL,22,RIGHTCOL,38.75,MBOXSIZE text 15,23.25,"COMP_NAME",HBFONT,14 text 15,24.35,"COMP_ADDR1",HFONT,12 text 15,25.35,"COMP_ADDR2",HFONT,12 text 15,26.35,"COMP_ADDR3",HFONT,12 text 49,23.25,"PR_BANK_NAME",DBFONT text 49,24.05,"PR_BANK_ADDR1",DFONT text 49,24.85,"PR_BANK_ADDR2",DFONT text 70,24.35,"PR_ROUTING",DBFONT # rtg # cbox 44,26.5,RIGHTCOL,28.5,1,crows=27.5::100,ccols=52 63 text 45,27,"Check #",ICFONT,10,cols=7,shade=0 text 45,28,{trim(get(63,2,7,""))},DBCFONT,11,cols=7 text 53,27,"Date",ICFONT,10,cols=10,shade=0 text 53,28,{trim(cut(58,27,8,""))},DBCFONT,11,cols=10 text 64,27,"Amount",IRFONT,10,cols=17,shade=0 cfont 64,28,MAXRCOLS,28,DBRFONT,11 text 2,31,"Pay",IFONT,14 text 7,31,{trim(cut(1,30,80,""))},DBFONT,italic,11,fit text 2,34,"Pay",IFONT text 2,35,"to the",IFONT text 2,36,"Order",IFONT text 2,37,"of",IFONT cmove 6,35,47,38,6,34 cfont 7,34,51,37,DBFONT,11 SIGNATURE_IMAGE 50,36,0,0,"SIGNATURE" box 50,37.25,30,1,3 text 50,35.5,"Check Void After 180 Days",ICFONT,cols=30 text 50,38,"Authorized Signature",ICFONT,cols=30 PR_MICR 15,39.5,"PR_MICR_ACCOUNTNO",{trim(get(64,41,7))} # top stub - employee's cerase 1,2,30,2 cbox LEFTCOL,21.5,MAXCOLS,21.5 text 15,1,"COMP_NAME",HBFONT,12 cbox LEFTCOL,1.5,MAXCOLS,3.5,MBOXSIZE,crows=2.5::DSHADE, ccols=15 33 45 54 64 text 2,2,"Emp No/Dept",ICFONT,cols=13 text 16,2,"Employee Name",ICFONT,cols=17 text 34,2,"SSN",ICFONT,cols=11 text 46,2,"Per Beg",ICFONT,cols=8 text 55,2,"Per End",ICFONT,cols=9 text 65,2,"Ck No.",ICFONT,cols=16 cfont 2,3,14,3,DBCFONT cfont 16,3,32,3,DBCFONT cfont 34,3,44,3,DBCFONT cfont 46,3,53,3,DBCFONT cfont 55,3,63,3,DBCFONT cfont 65,3,MAXRCOLS,3,DBCFONT cbox LEFTCOL,3.5,MAXCOLS,17.5,MBOXSIZE,crows=5.5::DSHADE, ccols=14 24 34 47 60 70 text 2,4.5,"Earnings",IFONT text 24,4.5,"Hrs/Units",IRFONT,black text 34,4.5,"Curr Amt",IRFONT text 47,4.5,"YTD",IRFONT text 48,4.5,"Deductions",IFONT text 70,4.5,"Curr Amt",IRFONT text 75,4.5,"YTD",IRFONT,cols=6 cfont 2,6,13,15,DFONT cfont 14,6,23,15,DBRFONT,black cfont 24,6,33,15,DBRFONT cfont 35,6,46,15,DBRFONT cfont 48,6,59,18,DFONT cfont 61,6,69,18,DBRFONT cfont 71,6,MAXRCOLS,18,DBRFONT text 2,16,{mcut(1,16,13,2,"","Y","Y")},IBFONT text 15,16,{mcut(17,16,9,2,"","Y","Y")},DBRFONT,cols=9 cbox LEFTCOL,18.5,MAXCOLS,20.5,MBOXSIZE,crows=19.5::100, ccols=13 25 37 48 60 71 text 2,19,"Pay Rate",IFONT,shade=0 text 25,19,"Curr Earn",IRFONT,shade=0 text 37,19,"Curr Ded",IRFONT,shade=0 text 48,19,"Net Pay",IRFONT,shade=0 text 60,19,"YTD Earn",IRFONT,shade=0 text 61,19,"YTD Ded",IRFONT,shade=0,cols=10 text 72,19,"YTD Net Pay",IRFONT,shade=0,cols=9 cfont 2,20,12,20,DBFONT cfont 14,20,24,20,DBRFONT cfont 26,20,36,20,DBRFONT cfont 38,20,47,20,DBRFONT cfont 49,20,59,20,DBRFONT cfont 61,20,70,20,DBRFONT cfont 72,20,MAXRCOLS,20,DBRFONT # Bottom stub - employer's cerase 1,42,30,42 cbox LEFTCOL,39.5,MAXCOLS,39.5 text 15,41,"COMP_NAME",HBFONT,12 cbox LEFTCOL,41.5,MAXCOLS,43.5,MBOXSIZE,crows=42.5::DSHADE, ccols=15 33 45 54 64 text 2,42,"Emp No/Dept",ICFONT,cols=13 text 16,42,"Employee Name",ICFONT,cols=17 text 34,42,"SSN",ICFONT,cols=11 text 46,42,"Per Beg",ICFONT,cols=8 text 55,42,"Per End",ICFONT,cols=9 text 65,42,"Ck No.",ICFONT,cols=16 cfont 2,43,14,43,DBCFONT cfont 16,43,32,43,DBCFONT cfont 34,43,44,43,DBCFONT cfont 46,43,53,43,DBCFONT cfont 55,43,63,43,DBCFONT cfont 65,43,MAXRCOLS,43,DBCFONT cbox LEFTCOL,43.5,MAXCOLS,57.5,MBOXSIZE,crows=45.5::DSHADE, ccols=14 24 34 47 60 70 text 2,44.5,"Earnings",IFONT text 24,44.5,"Hrs/Units",IRFONT,black text 34,44.5,"Curr Amt",IRFONT text 47,44.5,"YTD",IRFONT text 48,44.5,"Deductions",IFONT text 70,44.5,"Curr Amt",IRFONT text 75,44.5,"YTD",IRFONT,cols=6 cfont 2,46,13,55,DFONT cfont 14,46,23,55,DBRFONT,black cfont 24,46,33,55,DBRFONT cfont 35,46,46,55,DBRFONT cfont 48,46,59,58,DFONT cfont 61,46,69,58,DBRFONT cfont 71,46,MAXRCOLS,58,DBRFONT text 2,56,{mcut(1,56,13,2,"","Y","Y")},IBFONT text 15,56,{mcut(17,56,9,2,"","Y","Y")},DBRFONT,cols=9 cbox LEFTCOL,58.5,MAXCOLS,60.5,MBOXSIZE,crows=59.5::100, ccols=13 25 37 48 60 71 text 2,59,"Pay Rate",IFONT,shade=0 text 25,59,"Curr Earn",IRFONT,shade=0 text 37,59,"Curr Ded",IRFONT,shade=0 text 48,59,"Net Pay",IRFONT,shade=0 text 60,59,"YTD Earn",IRFONT,shade=0 text 61,59,"YTD Ded",IRFONT,shade=0,cols=10 text 72,59,"YTD Net Pay",IRFONT,shade=0,cols=9 cfont 2,60,12,60,DBFONT cfont 14,60,24,60,DBRFONT cfont 26,60,36,60,DBRFONT cfont 38,60,47,60,DBRFONT cfont 49,60,59,60,DBRFONT cfont 61,60,70,60,DBRFONT cfont 72,60,MAXRCOLS,60,DBRFONT end if # summary copy if copy 2 cerase 1,1,MAXCOLS,MAXROWS # title text 1,2,"Payroll Check Summary",HBCFONT,cols=MAXRCOLS,14 # summary text 25,6,{mget(14,1,21,8,"Y","Y")},HBFONT text 58,6,{mget(36,1,13,8,"Y","Y")},DBRFONT,11 # end of report text 2,15,{get(1,11,13)},HBCFONT,cols=MAXRCOLS cerase LEFTCOL,1,RIGHTCOL,MAXROWS end if [SO_Bol] # bill of lading rule set dsn_sample "/u0/unform_test/_oem/osas/txt7/bolading.txt" dsn_sample "/u0/unform_test/_oem/osas/txt7/bol2pg.txt" detect 64,1,"BILL" detect 122,2,"~[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]" # set up document constants local MAXCOLS=132 # max cols to output local MAXRCOLS=131 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local CUSTOMER_COPY=1 local FILE_COPY=2 local TOTALS_COPY=3 local MAX_COPIES=2 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Shipping Order - Bill of Lading" # view in pdf properties prejob { dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then copy_title$[CUSTOMER_COPY]="Customer Copy" if MAX_COPIES>=2 then copy_title$[FILE_COPY]="Accounting Copy" } prepage { carrier$=cut(16,2,25,"") carno$=cut(77,2,10,"") date$=cut(98,2,10,"") shipno$=cut(121,2,10,"") received$=mcut(1,3,132,6,"","y","") from$=mcut(10,9,30,5,"","y","") to$=mcut(83,9,30,5,"","y","") deliver$=cut(1,15,25,"") route$= cut(49,15,25,"") vehicle$=cut(115,15,5,"") #detail$=mcut(2,18,132,28,"","y","") placards$=cut(20,48,5,"") remit$=mcut(10,49,25,3,"","y","") codamt$=cut(90,51,14,"") emerg$=cut(107,48,30,"") codfee$=cut(120,51,13,"") total$=cut(120,53,13,"") freight$=cut(112,56,13,"") perunit$=cut(3,57,25,"") } precopy { } # header section cerase 1,1,MAXCOLS,17 text 13,4.5,{received$}, DFONT cbox LEFTCOL,1.5,MAXCOLS,3.5,MBOXSIZE,ccols=18::ISHADE 46.5 64::ISHADE 80 87::ISHADE 100 118::ISHADE cbox LEFTCOL,3.5,RIGHTCOL,10.5,MBOXSIZE text 1,1,"Straight Bill of Lading",DBCFONT,12,cols=MAXCOLS text 10,2.5,"Name of carrier",ICFONT,10 text 33,2.5,{carrier$},DBCFONT,10 text 48,2.5,"Carrier number",IFONT,10 text 66,2.5,{carno$},DBFONT,10 text 82,2.5,"Date",IFONT,10 text 89,2.5,{date$},DBFONT,10 text 101,2.5,"Shipper number",IFONT,10 text 119,2.5,{shipno$},DBFONT,10 # from & to cbox LEFTCOL,10.5,MAXCOLS,16,MBOXSIZE,ccols=10::ISHADE 64 75::ISHADE text 2,11.5,"From:\nShipper",ICFONT,10,cols=7.5 text 11.5,11.5,{from$},DBFONT,10 text 65,11.5,"To:\nConsignee",ICFONT,10,cols=10 cfont 47,11,MAXRCOLS,18,DBFONT,black # ship to addr text 77,11.5,{to$},DBFONT,10 # ribbon 1 cbox LEFTCOL,16,MAXCOLS,19,MBOXSIZE,crows=17.5::ISHADE, ccols=40 100 text 3,16.75,"Delivering",ICFONT,ccols=37 text 1.5,18.25,{deliver$},DBCFONT,10,cols=37 text 53,16.75,"Route",ICFONT,cols=30 text 53,18.25,{route$},DBCFONT,10, cols=30 text 101,16.75,"Vehicle Number",ICFONT,cols=30 text 101,18.25,{vehicle$},DBCFONT,10,cols=30 cerase 12,22,12,50 cerase 17,22,17,50 #cerase 81,22,81,50 cerase 86,22,86,50 cerase 105,22,105,50 cerase 116,22,119,50 #detail section cbox LEFTCOL,19,RIGHTCOL,50.5,MBOXSIZE,crows=21.5::DSHADE,ccols=11 16 68 77 95.5 108 117 cmove 1,18,MAXCOLS,46,1,22 text 1,19.75,"No. of\nUnits",IRFONT,cols=9 cmove 3,22,11,50,1,22 cfont 1,22,9.75,50,DBRFONT text 13.75,19.75,"Hm",ICFONT cfont 12,22,15,50,DCFONT text 17.5,19.75,"Kind of Packaging, Description of Articles, \nSpecial Marks and Exceptions",ILFONT cfont 17,22,69,50,DLFONT text 69,19.75,"Erg #",ICFONT,cols=8 cmove 82,22,85,50,70,22 cfont 70,22,74,50,DCFONT text 77,19.75,"Weight (subject \nto correction)",IRFONT,cols=18 cmove 87,22,102,50,70,22 cfont 76,22,94,50,DBRFONT text 97,19.75,"Class\n or Rate",ICFONT,cols=10 cmove 107,22,112,50,97,22 cfont 97,22,107,50,DCFONT text 110,19.75,"CK",ICFONT,cols=5 cfont 109,22,116,50,DCFONT text 118.5,19.75,"Charges \n(Carrier Use)",IRFONT,cols=13 cfont 118,22,131,50,DBRFONT # shade lines shade "~[0-9][0-9]@6,22,8,50", 10,0,79,1,DFONT,20 # watermark - large font with light shading WATERMARK 1,54.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # bottom sections cerase 1,50,MAXCOLS,MAXROWS cbox LEFTCOL,50.5,MAXCOLS,53,MBOXSIZE,ccols=23::ISHADE 39 58::ISHADE 83 104::ISHADE cbox LEFTCOL,53,102,56,MBOXSIZE,ccols=13::ISHADE 65 77::ISHADE cbox 102,53,MAXCOLS,57,MBOXSIZE, crows 55::ISHADE cbox LEFTCOL,56,102,62,MBOXSIZE, ccols=33.5 cbox 102,57,MAXCOLS,60,MBOXSIZE, ccols=112::ISHADE cbox 102,60,MAXCOLS,64,MBOXSIZE, crows=62::ISHADE cbox LEFTCOL,62,102,64,MBOXSIZE cbox LEFTCOL,64,MAXCOLS,66,MBOXSIZE,ccols=59 99 text 2.5,51.75,"Placards supplied?",IFONT text 23,51.75,{placards$}, DBCFONT,10,cols=16 text 3,54.5,"Remit To",IFONT text 14,53.5,{remit$},10, DBFONT text 40,51.25,"Driver's\n signature",ICFONT,cols=21 text 84,51.25,"Emergency\n response phone",ICFONT,cols=20 text 109,51.75,{emerg$},10,DBFONT text 105,54,"C.O.D. Fee",ICFONT, cols=25 text 116,56.5,{codfee$}, DBRFONT,10,cols=15 text 68,54,"C.O.D.\nAmount",IFONT text 82,54.5,"$",DBFONT text 81,54.5,{codamt$}, DBRFONT,10,cols=20 text 105,55.5, "___Prepaid",IFONT text 118,55.5, "___Collect",IFONT text 118,56.5, "$",DBFONT text 107.5,58,"Total\nCharges",ICFONT text 117,58.5,"$",DBFONT text 115,58.5,{total$}, DBRFONT,10, cols=16 text 105,61,"Freight charges are:",IFONT text 104,63,{freight$},DCFONT,10,cols=23 text 3.5,56.75,{mcut(1,52,35,4,"","y","")},DFONT text 40,56.75,{mcut(38,52,67,4,"","y","")},DFONT text 3,62.5,"This is to certify that the above materials are properly classified, described, packaged, marked, labeled, and in proper\ncondition for transportation, according to the applicable regulations of the Department of Transportation.",DFONT,8 text 3,61,"$",DBFONT text 3,61,{perunit$},DBFONT,10 text 40,61,"Signature of Consignor:",IFONT text 60,64.75,"Shipper, per",IFONT text 100,64.75,"Agent, per",IFONT # handle copy title cbox 1.7,64.3,30,65.7,1,100 text 1,65,{copy_title$[copy]},HBCFONT,12,cols=30,shade 0 [SO_Inv8.5x11] # handles invoice, quote, credit memo detect 62,6,"~ DATEMASK " detect 77,17,"~\.[0-9][0-9]" # set up document constants local MAXCOLS=80 # max cols to output local MAXRCOLS=79 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local CUSTOMER_COPY=1 local FILE_COPY=2 local TOTALS_COPY=3 local MAX_COPIES=3 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Invoice - 8.5 x 11" # view in pdf properties prejob { logocols=14,logorows=6 dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then copy_title$[CUSTOMER_COPY]="Customer Copy" if MAX_COPIES>=2 then copy_title$[FILE_COPY]="File Copy" } prepage { if trim(get(1,1,80))<>"" then : pcopies=CUSTOMER_COPY copy_title$[CUSTOMER_COPY]=trim(get(1,1,80)) endif # add zip barcode xrow=13;xcols=40 #merge "zmrg get zip" # get invoice title doc_title$="INVOICE",reprint$="" # get title from body of invoice, if available. # Must handle credit memo text/quote. x$=trim(cut(13,10,26,"")) x=pos("REPRINT"=x$) if x then reprint$="REPRINT" x=pos("C R E D I T"=X$) if x then doc_title$="CREDIT MEMO" x=pos("Q U O T E"=X$) if x then doc_title$="QUOTE" xcol=0,xrow=0 merge "zMrg get company info" shipto$=trim(cut(45,10,6,"")) due$=trim(get(70,17,11)),x$=set(70,17,11,"") totaldue$="" if title$="INVOICE" then : totaldue$="The total due on this invoice is $"+totaldue$+"." endif # continued? cont$="",sub_line=50 for i=50 to MAXROWS x=pos("(continued"=text$[i]) if x then : cont$="Continued on next page ..." sub_line=55 x$=set(x,i,30,"") break endif next i if cont$="" then : exec("cbox 1,58,RIGHTCOL,61,MBOXSIZE,crows=59.5::HSHADE 61,ccols=15 28 41 54 67") endif if cont$="" then exec("text 3,59,""Taxable"",HRFONT,cols=12,10") if cont$="" then exec("text 16,59,""Non-Taxable"",HRFONT,cols=12,10") if cont$="" then exec("text 29,59,""Freight"",HRFONT,cols=12,10") if cont$="" then exec("text 42,59,""Sales Tax"",HRFONT,cols=12,10") if cont$="" then exec("text 55,59,""Misc Charge"",HRFONT,cols=12,10") if cont$="" then exec("text 67,59,""Grand Total"",HBRFONT,cols=12,10") amount_paid$=trim(get(23,61,11)) amt_paid$=trim(get(36,61,15)) net_due$=trim(get(58,61,7)) nt_due$=trim(get(67,61,14)) if amount_paid$="" then goto no_amount_paid amount_paid$=amount_paid$(1,len(amount_paid$)-1) # remove colon net_due$=net_due$(1,len(net_due$)-1) # remove colon x$="cbox 61,61,RIGHTCOL,64,1,ccols=70::DSHADE,crows=62.5" exec(x$) x$="text 62,62,"+$22$+amount_paid$+$22$+",IFONT,10" exec(x$) x$="text 71,62,"+$22$+amt_paid$+$22$+",DBRFONT,10,cols=9" exec(x$) x$="text 62,63.5,"+$22$+net_due$+$22$+",IBFONT,10" exec(x$) x$="text 71,63.5,"+$22$+nt_due$+$22$+",DBRFONT,10,cols=9" exec(x$) no_amount_paid: # mark line types (D=detail, L=lot, R=remark/desc, S=serial for i=28 to 54 if mid(text$[i],4,3)="Lot" and mid(text$[i],38,7)="Ordered" then : i=i+1 goto bottom_loop endif if mid(text$[i],6,3)="Ser" and mid(text$[i],61,1)="." then goto bottom_loop if mid(text$[i],77,1)="." then goto bottom_loop # component? if mid(text$[i],2,17)="End of Components" then compon=0 if compon and len(trim(text$[i]))>2 and mid(text$[i],1,2)=" " then : text$[i](1,1)="C" i=i+1 goto bottom_loop endif if mid(text$[i],2,11)="Component :" then compon=1 # must be remark if text$[i]<>"" then text$[i](1,1)="R" bottom_loop: next i } precopy { x$=trim(get(1,21,MAXCOLS)) if copy=3 and x$<>"Run Totals:" then skip=1 if copy<3 and x$="Run Totals:" then skip=1 if copy=3 then doc_title$="Summary" merge "zMrg get watermark text" } # customer or file copy if copy CUSTOMER_COPY,FILE_COPY # default detail line local BROW=1 local EROW=MAXROWS cmove 1,28,MAXCOLS,53,1,29 cfont 2,BROW,21,EROW,DBFONT # item # cfont 23,BROW,24,EROW,DCFONT # tx cfont 26,BROW,30,EROW,DCFONT # uom cfont 32,BROW,41,EROW,DBRFONT # qty ord cfont 43,BROW,53,EROW,DBRFONT,black # qty ship cfont 55,BROW,65,EROW,DBRFONT # price cfont 67,BROW,MAXRCOLS,EROW,DBRFONT # ext cbox LEFTCOL,26,RIGHTCOL,55,MBOXSIZE,crows=27.5::DSHADE,ccols=22 25 31 42 54 66 text 2,27,"Item Information",IFONT text 23,27,"Tx",ICFONT,cols=2 text 26,27,"U/M",ICFONT,cols=5 text 32,27,"Ordered",IRFONT,cols=10 text 43,27,"Shipped",IRFONT,cols=11 text 55,27,"Unit Price",IRFONT,cols=11 text 67,27,"Extension",IRFONT,cols=13 # shade lines shade "~[0-9][0-9][0-9]@2,28,4,54", -.5,0,79,1,DSHADE # header section cerase 1,1,MAXCOLS,6 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=10:MBOXSIZE merge "zMrg Form Header" # Invoice block cbox 66,4,RIGHTCOL,10,1,ccols=72::ISHADE,crows=6 8 text 67,5,"Invoice",IFONT text 67,7,"Date",IFONT text 67,9,"Page",IFONT text 73,5,{trim(cut(52,6,8,""))},DBFONT text 73,7,{trim(cut(63,6,8,""))},DBFONT text 73,9,{trim(cut(72,6,7,""))},DBFONT # sold to cbox LEFTCOL,10,MAXCOLS,20,MBOXSIZE,ccols=7::ISHADE 40 46::ISHADE text 3,11,"Sold\nTo",ICFONT,cols=3 cmove 6,11,39,18,8,11 cfont 8,11,39,18,DBFONT,black # sold to addr text 2,13,{trim(cut(6,10,6,""))},DBFONT # ship to text 42,11,"Ship\nTo",ICFONT,cols=3 cmove 45,11,MAXRCOLS,18,47,11 cfont 47,11,MAXRCOLS,18,DBFONT,black # ship to addr text 41,13,{shipto$},DBFONT text 47,19,{totaldue$},DBFONT # zip bar #barcode 47,16,{shipzip$},900,12.0,2 # ribbon 1 cbox LEFTCOL,20,MAXCOLS,23,MBOXSIZE,crows=21.5::ISHADE,ccols=7 13 25 37 46 58 70 text 2,21,"Slsp1",ICFONT,cols=5 text 8,21,"Slsp2",ICFONT,cols=5 text 14,21,"Due Date",ICFONT,cols=11 text 26,21,"Disc Due Date",ICFONT,cols=11 text 38,21,"Order No",ICFONT,cols=8 text 47,21,"Order Date",ICFONT,cols=11 text 59,21,"Ship Date",ICFONT,cols=11 text 71,21,"Ship No",ICFONT,cols=9 cfont 2,22,6,22,DBCFONT # slsp 1 cfont 8,22,12,22,DBCFONT # slsp 2 cfont 14,22,24,22,DBCFONT # due date cfont 26,22,36,22,DBCFONT # disc due date cfont 38,22,45,22,DBCFONT,black # order # cfont 47,22,57,22,DBCFONT,black # order date cfont 59,22,69,22,DBCFONT # ship date cfont 71,22,MAXRCOLS,22,DBCFONT # ship # # ribbon 2 cbox LEFTCOL,23,MAXCOLS,26,MBOXSIZE,crows=24.5::ISHADE,ccols=18 45 text 2,24,"Terms Description",ICFONT,cols=17 text 19,24,"Customer PO No",ICFONT,cols=25 text 46,24,"Ship Via",ICFONT,cols=34 cfont 2,25,17,25,DBCFONT # terms cfont 19,25,44,25,DBCFONT,black # cust po cfont 46,25,MAXRCOLS,25,DBCFONT,black # ship via # detail section # lot line font "Lot@4,28,6,54",0,0,3,1,IRFONT # lot font "Lot@4,28,6,54",4,0,20,1,DBFONT # lot id font "Lot@4,28,6,54",34,0,9,2,IRFONT # lot ord/ship font "Lot@4,28,6,54",43,0,13,2,DBRFONT,black # lot qty font "Lot@4,28,6,54",57,0,10,2,IFONT # lot uom # ser line font "Ser@6,28,8,54",0,0,3,1,IRFONT # ser font "Ser@6,28,8,54",4,0,20,1,DBFONT # ser id # component lines font "C@1,28,1,54",2,0,30,1,DBFONT # item # font "C@1,28,1,54",2,1,45,1,DFONT # desc font "C@1,28,1,54",44,0,5,1,DBCFONT # uom font "C@1,28,1,54",50,0,19,1,DBRFONT # qty # description font "R@1,28,1,54",1,0,77,1,DFONT # description cerase 1,28,1,54 # watermark - large font with light shading WATERMARK 1,54.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # message area cbox LEFTCOL,55,MAXCOLS,58,MBOXSIZE cfont 2,56,55,57,ILFONT,black # mesg cfont 57,57,66,57,IBRFONT # subtotal: cfont 67,57,MAXRCOLS,57,DBRFONT # subtotal amt # footer text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS text 1,{MAXROWS+.5},{cont$},DBRFONT,cols=MAXRCOLS # totals cfont 2,60,14,60,DBRFONT # taxable cfont 16,60,27,60,DBRFONT # non-taxable cfont 29,60,40,60,DBRFONT,black # freight cfont 42,60,53,60,DBRFONT # sales tax cfont 55,60,66,60,DBRFONT,black # misc cfont 68,60,MAXRCOLS,60,DBRFONT,10 # grand total end if if copy TOTALS_COPY cfont 21,21,40,50,HFONT cfont 42,21,53,50,DFONT,right cfont 54,21,54,50,DFONT,black bold "Total",-5,0,25,1 end if [SO_InvLaser] # handles invoice, quote, credit memo detect 111,6,"~ DATEMASK" detect 0,17,"~\.[0-9][0-9]" # set up document constants local MAXCOLS=132 # max cols to output local MAXRCOLS=131 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local CUSTOMER_COPY=1 local FILE_COPY=2 local MAX_COPIES=2 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Invoice - laser" # view in pdf properties prejob { logocols=16,logorows=7 dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then : copy_title$[CUSTOMER_COPY]="Customer Copy" endif if MAX_COPIES>=2 then : copy_title$[FILE_COPY]="File Copy" endif } prepage { if trim(get(1,1,80))<>"" then : pcopies=CUSTOMER_COPY copy_title$[CUSTOMER_COPY]=trim(get(1,1,80)) endif # get invoice title doc_title$="INVOICE",reprint$="" # get title from body of invoice, if available. # Must handle credit memo text/quote. x$=trim(cut(18,10,26,"")) x=pos("REPRINT"=x$) if x then reprint$="REPRINT" x=pos("C R E D I T"=X$) if x then doc_title$="CREDIT MEMO" x=pos("Q U O T E"=X$) if x then doc_title$="QUOTE" merge "zMrg get watermark text" xcol=0,xrow=0 merge "zMrg get company info" shipto$=trim(get(45,10,10)) if shipto$<>"" then : shipto$="Your ship to code is "+shipto$ endif totaldue$="" due$=trim(cut(110,17,12,"")) if doc_title$="INVOICE" then : totaldue$="Your total due is "+due$ endif # mark memo lines for i=28 to 54 if mid(text$[i],4,3)="Lot" and mid(text$[i],46,7)="Ordered" then : i=i+1 goto bottom_loop # lot line endif if mid(text$[i],6,3)="Ser" and mid(text$[i],107,1)="." then : goto bottom_loop # serial line endif if mid(text$[i],128,1)="." then goto bottom_loop # detail line # component? if mid(text$[i],2,17)="End of Components" then compon=0 if compon and len(trim(text$[i]))>2 and mid(text$[i],1,2)=" " then : text$[i](1,1)="C" i=i+1 goto bottom_loop endif if mid(text$[i],2,11)="Component :" then compon=1 # must be remark/desc if text$[i]<>"" then : text$[i](1,1)="R" bottom_loop: endif next i # continued? cont$="",sub_line=50 for i=50 to MAXROWS x=pos("(continued"=text$[i]) if x then : cont$="Continued on next page ..." sub_line=55; x$=set(x,i,30,"") break endif next i if cont$="" then : exec("cbox 1,58,RIGHTCOL,61,MBOXSIZE,crows=59.5 61::HSHADE,ccols=27 48 69 90 114") endif if cont$="" then exec("text 2,60.5,""Taxable"",HRFONT,cols=25,10") if cont$="" then exec("text 29,60.5,""Non-Taxable"",HRFONT,cols=19,10") if cont$="" then exec("text 50,60.5,""Freight"",HRFONT,cols=19,10") if cont$="" then exec("text 71,60.5,""Sales Tax"",HRFONT,cols=19,10") if cont$="" then exec("text 92,60.5,""Misc Charge"",HRFONT,cols=22,10") if cont$="" then exec("text 115,60.5,""Grand Total"",HBRFONT,cols=16,10") amount_paid$=trim(get(10,60,20)) amt_paid$=trim(get(31,60,20)) net_due$=trim(get(50,60,20)) nt_due$=trim(get(70,60,20)) if amount_paid$="" then goto no_amount_paid amount_paid$=amount_paid$(1,len(amount_paid$)-1) # remove colon net_due$=net_due$(1,len(net_due$)-1) # remove colon x$="cbox 90,61,MAXCOLS,64,1,ccols=114::DSHADE,crows=62.5" exec(x$) x$="text 91,62,"+$22$+amount_paid$+$22$+",IFONT,10" exec(x$) x$="text 118,62,"+$22$+amt_paid$+$22$+",DBRFONT,10,cols=14" exec(x$) x$="text 91,63.5,"+$22$+net_due$+$22$+",IBFONT,10" exec(x$) x$="text 118,63.5,"+$22$+nt_due$+$22$+",DBRFONT,10,cols=14" exec(x$) no_amount_paid: } # default detail line local BROW=1 local EROW=MAXROWS cfont 2,BROW,39,EROW,DBFONT # item # cfont 41,BROW,43,EROW,DCFONT # tx cfont 45,BROW,49,EROW,DCFONT # uom cfont 51,BROW,69,EROW,DBRFONT # qty ord cfont 71,BROW,89,EROW,DBRFONT,black # qty ship cfont 91,BROW,111,EROW,DBRFONT # price cfont 113,BROW,MAXRCOLS,EROW,DBRFONT # ext cbox LEFTCOL,26,MAXCOLS,55,MBOXSIZE,crows=27.5::DSHADE,ccols=40 44 50 70 90 112 text 2,27,"Item Information",IFONT text 41,27,"Tx",ICFONT,cols=3 text 45,27,"U/M",ICFONT,cols=5 text 51,27,"Ordered",IRFONT,cols=19 text 71,27,"Shipped",IRFONT,cols=19 text 91,27,"Unit Price",IRFONT,cols=21 text 113,27,"Extension",IRFONT,cols=19 # header section cerase 1,1,MAXCOLS,9 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=10:MBOXSIZE merge "zMrg Form Header" # Invoice block cbox 111,4,MAXCOLS,10,1,ccols=120::ISHADE,crows=6 8 text 112,5,"Invoice",IFONT text 112,7,"Date",IFONT text 112,9,"Page",IFONT text 121,5,{trim(cut(112,7,8,""))},DBFONT text 121,7,{trim(cut(112,6,8,""))},DBFONT text 121,9,{trim(cut(112,4,7,""))},DBFONT # sold to cerase 49,10,59,10 cbox LEFTCOL,10,MAXCOLS,20,MBOXSIZE,ccols=12::ISHADE 67 79::ISHADE text 1,11,"Sold\nTo:",ICFONT,cols=11 cfont 10,11,66,18,DBFONT,black # sold to addr text 1,13,{trim(cut(10,10,6,""))},DBCFONT, cols=11 cmove 10,11,66,18,17,11 # ship to text 68,11,"Ship\nTo:",ICFONT,cols=11 cfont 76,11,MAXRCOLS,18,DBFONT,black # ship to addr text 76,18,{shipto$},DBFONT text 80.75,19,{totaldue$},DBFONT cmove 76,11,MAXRCOLS,18,85,11 # ribbon 1 cbox LEFTCOL,20,MAXCOLS,23,MBOXSIZE,crows=21.5::ISHADE, ccols=7 13 24 38 60 78 96 119 text 2,21,"Slsp1",ICFONT,cols=5 text 8,21,"Slsp2",ICFONT,cols=5 text 25,21,"Due Date",ICFONT,cols=13 text 39,21,"Disc Due Date",ICFONT,cols=21 text 61,21,"Order No",ICFONT,cols=17 text 79,21,"Order Date",ICFONT,cols=17 text 97,21,"Ship Date",ICFONT,cols=22 text 120,21,"Ship No",ICFONT,cols=12 cfont 2,22,6,22,DBCFONT # slsp 1 cfont 8,22,23,22,DBCFONT # slsp 2 cfont 25,22,37,22,DBCFONT # due date cfont 39,22,59,22,DBCFONT # disc due date cfont 61,22,77,22,DBCFONT,black # order # cfont 79,22,95,22,DBCFONT # order date cfont 97,22,118,22,DBCFONT # ship date cfont 120,22,MAXRCOLS,22,DBCFONT # ship # # ribbon 2 cbox LEFTCOL,23,MAXCOLS,26,MBOXSIZE,crows=24.5::ISHADE,ccols=32 78 text 2,24,"Terms Description",ICFONT,cols=30 text 33,24,"Customer PO No",ICFONT,cols=45 text 79,24,"Ship Via",ICFONT,cols=53 cfont 2,25,31,25,DBCFONT # terms cfont 33,25,77,25,DBCFONT,black # cust po cfont 79,25,MAXRCOLS,25,DBCFONT,black # ship via # detail section # lot line font "Lot@4,28,6,54",0,0,3,1,IRFONT # lot font "Lot@4,28,6,54",4,0,30,1,DBFONT # lot id font "Lot@4,28,6,54",42,0,12,2,IRFONT # lot ord/ship font "Lot@4,28,6,54",59,0,12,2,DBRFONT,black # lot qty font "Lot@4,28,6,54",73,0,10,2,IFONT # lot uom # ser line font "Ser@6,28,8,54",0,0,3,1,IRFONT # ser font "Ser@6,28,8,54",4,0,20,1,DBFONT # ser id # component lines font "C@1,28,1,54",2,0,30,1,DBFONT # item # font "C@1,28,1,54",2,1,45,1,DFONT # desc font "C@1,28,1,54",44,0,5,1,DBCFONT # uom font "C@1,28,1,54",50,0,19,1,DBRFONT # qty # description font "R@1,28,1,54",1,0,77,1,DFONT # description cerase 1,28,1,54 # watermark - large font with light shading WATERMARK 1,54.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # message area cbox LEFTCOL,55,MAXCOLS,58,MBOXSIZE cfont 2,56,92,57,IFONT # mesg cfont 94,57,110,57,DBRFONT # subtotal: cfont 114,57,MAXRCOLS,57,DBRFONT # subtotal amt # footer text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS text 1,{MAXROWS+.5},{cont$},DBRFONT,cols=MAXRCOLS # shade lines shade "~\.[0-9][0-9]@128,28,130,54",-126.5,0,131,1,DSHADE # totals cerase LEFTCOL,60,RIGHTCOL,60 cfont 2,59,26,59,DBRFONT # taxable cfont 28,59,47,59,DBRFONT # non-taxable cfont 49,59,68,59,DBRFONT,black # freight cfont 70,59,89,59,DBRFONT # sales tax cfont 91,59,113,59,DBRFONT,black # misc cfont 115,59,MAXRCOLS,59,DBRFONT,10 # grand total [SO_InvPlain] # handles invoice, quote, credit memo detect 0,2,"~(I N V O I C E)|(C R E D I T)|(Q U O T E)" # set up document constants local MAXCOLS=120 # max cols to output local MAXRCOLS=119 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local CUSTOMER_COPY=1 local FILE_COPY=2 local MAX_COPIES=2 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Invoice - plain" # view in pdf properties prejob { logocols=14,logorows=6 dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then : copy_title$[CUSTOMER_COPY]="Customer Copy" endif if MAX_COPIES>=2 then : copy_title$[FILE_COPY]="File Copy" endif } prepage { if trim(get(70,1,80))<>"" then : pcopies=CUSTOMER_COPY copy_title$[CUSTOMER_COPY]=trim(get(70,1,80)) endif # get invoice title doc_title$="INVOICE",reprint$="" # get title from body of invoice, if available. # Must handle credit memo text/quote. x$=trim(cut(70,2,50,"")) x=pos("REPRINT"=x$) if x then reprint$="REPRINT" x=pos("C R E D I T"=X$) if x then doc_title$="CREDIT MEMO" x=pos("Q U O T E"=X$) if x then doc_title$="QUOTE" merge "z Mrg get watermark text" xcol=30,xrow=1 merge "zMrg get company info" amount_paid$=trim(get(80,55,20)) amt_paid$=trim(get(100,55,20)) net_due$=trim(get(80,57,20)) nt_due$=trim(get(100,57,20)) if amount_paid$="" then goto no_amount_paid amount_paid$=amount_paid$(1,len(amount_paid$)-1) # remove colon net_due$=net_due$(1,len(net_due$)-1) # remove colon x$="cbox 85,53,MAXCOLS,56,1,ccols=104::DSHADE,crows=54.5" exec(x$) x$="text 86,54,"+$22$+amount_paid$+$22$+",IFONT,11" exec(x$) x$="text 108,54,"+$22$+amt_paid$+$22$+",DBRFONT,11,cols=12" exec(x$) x$="text 86,55.5,"+$22$+net_due$+$22$+",IBFONT,11" exec(x$) x$="text 108,55.5,"+$22$+nt_due$+$22$+",DBRFONT,11,cols=12" exec(x$) no_amount_paid: # continued? cont$="",sub_line=47 for i=47 to MAXROWS x=pos("(continued"=text$[i]) if x then : cont$="Continued on next page ..." sub_line=55 x$=set(x,i,30,"") break endif next i if cont$="" then : exec("cbox LEFTCOL,51.5,MAXCOLS,53.5,MBOXSIZE,crows=52.5::ISHADE, ccols=25 40 55 70 85") endif if cont$<>"" then : exec("erase 1,52,MAXCOLS,53") endif } # more room at top cmove LEFTCOL,1,RIGHTCOL,MAXROWS,1,2 # default detail line local BROW=1 local EROW=MAXROWS cfont 2,BROW,45,EROW,DBLFONT # item # cfont 47,BROW,54,EROW,DFONT,black # o/s cfont 55,BROW,68,EROW,DBRFONT # qty cfont 70,BROW,76,EROW,DCFONT # units cfont 78,BROW,99,EROW,DBRFONT # price cfont 101,BROW,MAXRCOLS,EROW,DBRFONT # ext cbox LEFTCOL,19.5,MAXCOLS,48,MBOXSIZE,CROWS=20.5::DSHADE, ccols=46 54 69 77 100 local BROW=20 local EROW=20 cfont 2,BROW,45,EROW,ILFONT # item # cerase 47,BROW,68,EROW # mislabeling text 50.5,BROW,"O/S",ICFONT text 66.5, BROW,"Qtys", ICFONT # qtys #cfont 47,BROW,68,EROW,ICFONT # qtys cfont 70,BROW,76,EROW,ICFONT # units cfont 78,BROW,99,EROW,IRFONT # price cfont 101,BROW,MAXRCOLS,EROW,IRFONT # ext # header section cerase 1,1,MAXCOLS,8 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=9:MBOXSIZE merge "zMrg Form Header" # page block text 1,7,{trim(get(111,6,10))},HFONT,right,cols=MAXRCOLS # address region cbox LEFTCOL,9,MAXCOLS,16,MBOXSIZE,ccols=10::ISHADE 61 70::ISHADE cmove 11,10,18,10,2,10 cmove 20,9,60,15,11,9 cmove 71,10,78,10,62,10 cmove 81,9,MAXRCOLS,15,71.5,9 cerase 1,10,18,10,ICFONT, cols=6 text 6,10,"Ship\nTo:",ICFONT cfont 11,10,60,15,DBFONT cerase 62,10,70,10,ICFONT, cols=8 text 66,10,"Sold\nTo:",ICFONT cfont 71,8,MAXRCOLS,15,DBFONT text 1,12,{trim(get(20,7,10))},DBCFONT, cols=9 # subhead 1 cbox LEFTCOL,16,MAXCOLS,18.5,MBOXSIZE,crows=17.5::ISHADE, ccols=30 38 48 64 85 106 cfont 2,17,29,17,ICFONT,black cfont 31,17,37,17,ICFONT,black cfont 39,17,48,17,ICFONT,black cfont 50,17,63,17,ICFONT,black cfont 65,17,84,17,ICFONT,black cfont 86,17,105,17,ICFONT,black cfont 107,17,MAXCOLS,17,ICFONT cfont 2,18,29,18,DBCFONT,black cfont 31,18,37,18,DBCFONT,black cfont 39,18,48,18,DBCFONT,black cfont 39,19,84,19,DBCFONT,black cfont 50,18,63,18,DBCFONT,black cfont 65,18,84,18,DBCFONT,black cfont 86,18,105,18,DBCFONT,black cfont 107,18,MAXCOLS,18,DBCFONT,black # watermark - large font with light shading WATERMARK 1,47.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # message area cbox LEFTCOL,48,MAXCOLS,51.5,MBOXSIZE cfont 2,49,91,51,IFONT,black cfont 93,51,102,51,IFONT,black # shade lines shade "~[0-9][0-9][0-9]@11,22,13,46",-9.5,0,118.75,1,DSHADE # item descs font "~[0-9][0-9][0-9]@11,20,13,46",-9,1,44,1,DLFONT # totals cfont 1,52,24,52,IRFONT,black cfont 26,52,39,52,IRFONT,black cfont 41,52,54,52,IRFONT,black cfont 56,52,69,52,IRFONT,black cfont 71,52,84,52,IRFONT,black cfont 86,52,MAXRCOLS,52,IRFONT,black cfont 1,53,24,53,DBRFONT,black cfont 26,53,39,53,DBRFONT,black cfont 41,53,54,53,DBRFONT,black cfont 56,53,69,53,DBRFONT,black cfont 71,53,84,53,DBRFONT,black cfont 86,53,MAXRCOLS,53,DBRFONT,black text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS text 1,{MAXROWS+.5},{cont$},DBRFONT,cols=MAXRCOLS cerase 80,55,MAXCOLS,58 [SO_InvStd] detect 0,10,"~DATEMASK" detect 80,1,"Page" detect 98,1,"Page" # set up document constants local MAXCOLS=93 # max cols to output local MAXRCOLS=92 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows page 51 local CUSTOMER_COPY=1 local REMITTANCE_COPY=2 local FILE_COPY=3 local MAX_COPIES=3 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Invoice - std" # view in pdf properties prejob { logocols=14,logorows=6 dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then : copy_title$[CUSTOMER_COPY]="Customer Copy" endif if MAX_COPIES>=2 then : copy_title$[REMITTANCE_COPY]="Remittance Copy" endif if MAX_COPIES>=3 then : copy_title$[FILE_COPY]="File Copy" endif } prepage { if trim(get(50,1,27))<>"" then : pcopies=CUSTOMER_COPY copy_title$[CUSTOMER_COPY]=trim(get(50,1,27)) endif # get invoice title doc_title$="INVOICE" pageno$=trim(get(80,1,10)) custno$=trim(get(8,2,10)) title$=trim(get(50,2,40)) if title$="" then title$="INVOICE" x$=title$ merge "zMrg get watermark text" xcol=0,xrow=0 merge "zMrg get company info" # replace dbl space with ff's before removing single spaces x=pos(" "=x$) while x>0 x$(x,1)=$ff$ x=pos(" "=x$) wend # remove <'s and >'s and extra spaces x=pos("<"=x$) if x=0 then x=pos(">"=x$) if x=0 then x=pos(" "=x$) while x>0 x$=trim(x$(1,x-1)+x$(x+1)) x=pos("<"=x$) if x=0 then x=pos(">"=x$) if x=0 then x=pos(" "=x$) wend # now remove ff's x=pos($ff$=x$) while x>0 x$(x,1)="" x=pos($ff$=x$) wend if x$>"" then title$=x$ # now move down to allow space for logo, etc. for i=MAXROWS to 9 step -1 text$[i]=text$[i-6] text$[i-6]="" next i remit$="Remittance Copy - Please return with payment" # continued? cont$="",sub_line=30 for i=30 to MAXROWS x=pos("(continued"=text$[i]) if x then : cont$="Continued on next page ..." sub_line=55 x$=set(x,i,30,"") break endif next i if cont$="" then : exec("cbox LEFTCOL,47,MAXCOLS,50,1,crows=48.5::ISHADE, ccols=14 27 40 52 64") endif if cont$="" then exec("text 1,48,""Non-Taxable"",IRFONT,cols=13") if cont$="" then exec("text 15,48,""Taxable"",IRFONT,cols=12") if cont$="" then exec("text 28,48,""Sales Tax"",IRFONT,cols=12") if cont$="" then exec("text 41,48,""Freight"",IRFONT,cols=11") if cont$="" then exec("text 53,48,""Misc"",IRFONT,cols=11") if cont$="" then exec("text 65,48,""Invoice Total"",IBRFONT,cols=27") } cmove LEFTCOL,1,RIGHTCOL,MAXROWS,2,2 # default detail line #cmove 2,20,93,43,2,21 local BROW=1 local EROW=MAXROWS cfont 2,BROW,36,EROW,DBFONT # item # cfont 38,BROW,45,EROW,DFONT,black # o/s cfont 46,BROW,59,EROW,DBRFONT # qty cfont 61,BROW,65,EROW,DCFONT # units cfont 67,BROW,80,EROW,DBRFONT # price cfont 82,BROW,92,EROW,DBRFONT # ext cbox LEFTCOL,18.5,MAXCOLS,44,MBOXSIZE,CROWS=19.5::DSHADE, ccols=37 44 60 66 81 text 2,19,"Item/Description",ILFONT text 37,19,"O/S",ICFONT, cols=8 text 38,19,"Quantities",IRFONT,cols=22 text 61,19,"Units",ICFONT,cols=5 text 67,19,"Price",IRFONT,cols=14 text 82,19,"Amount",IRFONT,cols=11 # header section cerase 1,1,MAXCOLS,8 cerase 93,1,110,MAXROWS cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=9:MBOXSIZE merge "zMrg Form Header" # page block text 1,8,{pageno$},HRFONT,cols=MAXRCOLS # address region cbox LEFTCOL,9,MAXCOLS,15,ccols=7::ISHADE 44 50::ISHADE text 1,10,"Sold\nTo",ICFONT, cols=7 text 2,12,{custno$},DBFONT, cols=6 text 44,10,"Ship\nTo",ICFONT, cols=7 cfont 8,8,43,14,DBLFONT cmove 52,8,MAXRCOLS,14,51,8 cfont 51,8,MAXRCOLS,14,DBFONT # subhead 1 cbox LEFTCOL,15,MAXCOLS,17.5,MBOXSIZE,crows=16.5::ISHADE,ccols=12 19 34 45 67 83 cbox LEFTCOL,17.5,MAXCOLS,18.5,MBOXSIZE,ccols=19 67 text 1,16,"Date",ICFONT,cols=11 text 13,16,"Rep ID",ICFONT, cols=5.5 text 20,16,"Order No",ICFONT, cols=14 text 35,16,"Ord Date",ICFONT,cols=10 text 46,16,"Ship Via",ICFONT, cols=20 text 68,16,"Terms",ICFONT, cols=15 text 84,16,"Invoice No",ICFONT, cols=9 cfont 1,17,11,17,DBCFONT cfont 13,17,18,17,DBCFONT cfont 20,17,33,17,DBCFONT cfont 20,18,66,18,DBCFONT cfont 35,17,44,17,DBCFONT cfont 46,17,66,17,DBCFONT cfont 68,17,82,17,DBCFONT cfont 84,17,92,17,DBCFONT # watermark - large font with light shading WATERMARK 1,43.25,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # shade lines shade "~[0-9][0-9][0-9]@2,22,4,39",-.5,0,92,1,DSHADE #item descs font "~[0-9][0-9][0-9]@2,20,4,39",0,1,35,1,DLFONT # message area cbox LEFTCOL,44,MAXCOLS,47,MBOXSIZE cfont 1,45,MAXCOLS,45,IFONT,black cfont 1,46,66,46,IFONT,black cfont 68,46,78,46,IFONT cfont 79,46,91,46,IRFONT,black # totals cfont 1,49,13,49,DBRFONT cfont 15,49,26,49,DBRFONT cfont 28,49,39,49,DBRFONT cfont 41,49,51,49,DBRFONT,black cfont 53,49,63,49,DBRFONT cfont 65,49,92,49,DBRFONT,black text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS text 1,{MAXROWS+.5},{cont$},DBRFONT,cols=MAXRCOLS [SO_PackListPlain] detect 0,1,"P A C K I N G L I S T" # set up document constants local MAXCOLS=125 # max cols to output local MAXRCOLS=124 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local CUSTOMER_COPY=1 local MAX_COPIES=1 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Pack List - plain" # view in pdf properties prejob { logocols=14,logorows=6 doc_title$="PACKING LIST" merge "zMrg get watermark text" # set up copy titles dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then copy_title$[CUSTOMER_COPY]="Customer Copy" } prepage { if trim(get(80,2,80))<>"" then : pcopies=CUSTOMER_COPY copy_title$[CUSTOMER_COPY]=trim(get(80,2,80)) endif xcol=31,xrow=2 merge "zMrg get company info" shipto$="" soldto$="" if trim(get(26,11,10))<>"" then : shipto$=trim(cut(26,11,10,"")) endif if trim(get(67,11,10))<>"" then : soldto$=trim(cut(67,11,10,"")) endif # continued? nextpageno$="" cont$="" nextpageno$=get(119,8,1,1,pagenum+1) if nextpageno$<>"1" then : cont$="Continued on Next Page..." if nextpageno$="" then : cont$="" endif endif } cmove LEFTCOL,1,MAXCOLS,MAXROWS,1,4 # default detail line cbox LEFTCOL,21.5,RIGHTCOL,64,MBOXSIZE,crows=22.5::DSHADE,ccols=14 65 72 88 107 local BROW=1 local EROW=MAXROWS cfont 7,BROW,13,EROW,DBLFONT # line # cfont 15,BROW,53,EROW,DFONT # item #/desc cfont 55,BROW,64,EROW,DBCFONT # bin cfont 66,BROW,71,EROW,DCFONT # units cfont 73,BROW,87,EROW,DBRFONT # qty ord cfont 89,BROW,106,EROW,DBRFONT # qty ship cfont 108,BROW,MAXRCOLS,EROW,DBRFONT # qty b/o local BROW=22 local EROW=22 cfont 7,BROW,13,EROW,ILFONT # line # cfont 15,BROW,53,EROW,IFONT # item #/desc cfont 55,BROW,64,EROW,ICFONT # bin cfont 66,BROW,71,EROW,ICFONT # units cfont 73,BROW,87,EROW,IRFONT # qty ord cfont 89,BROW,106,EROW,IRFONT # qty ship cfont 108,BROW,MAXRCOLS,EROW,IRFONT # qty b/o # header section cerase 1,1,MAXCOLS,7 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=9.5:MBOXSIZE merge "zMrg Form Header" # right header cbox 100,5.5,RIGHTCOL,7.5,1,ccols=115::ISHADE,crows=6.5 text 101,6,"Batch No.",IFONT text 116,6,{trim(cut(83,4,6,""))},DBFONT text 101,7,"Picking Slip #",IFONT text 116,7,{trim(cut(107,5,15,""))},DBFONT # ribbon section cbox LEFTCOL,9.5,RIGHTCOL,12.5,MBOXSIZE,crows=10.5::ISHADE, ccols= 22 34 44 55 72 115 cbox 92,9.5,115,11.5 cfont 8,10,20,10,ILFONT cfont 22,10,33,10,ICFONT cfont 35,10,43,10,ICFONT cfont 45,10,54,10,ICFONT cfont 56,10,71,10,ICFONT cfont 73,10,90,10,ICFONT cfont 92,10,113,10,ICFONT cfont 115,10,MAXCOLS,10,ICFONT cfont 8,11,20,11,DBLFONT,black cfont 22,11,33,11,DBCFONT,black cfont 35,11,43,11,DBCFONT,black cfont 45,11,54,11,DBCFONT,black cfont 56,11,71,11,DBCFONT,black cfont 73,11,90,11,DBCFONT,black cfont 73,12,113,12,DBFONT,black cfont 92,11,113,11,DBCFONT,black cfont 115,11,MAXCOLS,11,DBCFONT,black #remove ship to and sold to cerase 16,15,24,15 cerase 57,15,65,15 # ship to section cbox LEFTCOL,12.5,MAXCOLS,21.5,MBOXSIZE,ccols=10::ISHADE 57 66::ISHADE text 2,13,"Ship\nTo:",ICFONT,cols=8 text 11,13,{mcut(26,12,30,4,"","Y","Y")},DBFONT text 3,15,{shipto$},DBFONT #shade lines shade "~[0-9][0-9][0-9]@11,23,13,60",-9.5,0,124,1,DSHADE #item descriptions font "~[0-9][0-9][0-9]@11,23,13,60",4,0,10,1,DBLFONT # sold to section text 58,13,"Sold\nTo:",ICFONT,cols=8 text 67,13,{mcut(67,12,30,4,"","Y","Y")},DBFONT text 58.5,15,{soldto$},DBFONT # watermark - large font with light shading WATERMARK 1,63.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # footer text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS text 1,{MAXROWS+.5},{cont$},DBRFONT,cols=MAXRCOLS cfont 2,63,MAXCOLS,65,IFONT # memo lines [SO_PickListStd] detect 0,1,"Batch" detect 0,5,"~[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9] " detect 0,5,"~ DATEMASK " detect 56,9,"~ [A-Z0-9a-z*]+" detect 56,10,"~ [A-Z0-9a-z]+" # set up document constants local MAXCOLS=107 # max cols to output local MAXRCOLS=106 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows page 66 local WHSE_COPY=1 local MAX_COPIES=1 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Pick List - std" # view in pdf properties prejob { logocols=12,logorows=6 # set up copy titles dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then : if pick then : copy_title$[WHSE_COPY]="Warehouse Copy" else copy_title$[WHSE_COPY]="Customer Copy" endif endif } prepage { if trim(get(1,2,70))<>"" then : pcopies=WHSE_COPY copy_title$[WHSE_COPY]=trim(get(1,2,70)) endif xcol=0,xrow=0 merge "zMrg get company info" doc_title$="PICKING LIST" batchno$=trim(get(83,1,6)) pslipno$=trim(get(100,2,6)) custno$=trim(get(57,9,10));x$=set(57,9,10,"") for i=MAXROWS to 5 step -1 text$[i]=text$[i-3] text$[i-3]="" next i # continued? cont$="",sub_line=52 for i=52 to MAXROWS x=pos("(continued"=text$[i]) if x then : cont$="Continued on next page ..." sub_line=55 x$=set(x,i,30,"") break endif next i } cmove LEFTCOL,1,RIGHTCOL,MAXROWS,2,2 # header section cerase 1,1,MAXCOLS,7 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=9:MBOXSIZE merge "zMrg Form Header" # right header cbox 80,6.5,MAXCOLS,9,1,crows=7.5::ISHADE,ccols=95 text 81,7,"Picking Slip #",ICFONT, cols=14 text 96,7,"Batch #",ICFONT, cols=11 text 81,8,{pslipno$},DBCFONT, cols=14 text 96,8,{batchno$},DBCFONT, cols=11 # subhead cbox LEFTCOL,9,MAXCOLS,10.5,1,ISHADE,ccols=10 20 31 42 57 69 101 cbox LEFTCOL,10.5,57,11.5,ccols=10 20 31 42 cbox 69,10.5,MAXCOLS,11.5,ccols=101 57 cbox 57,9,57,12.5 cbox 101,9,101,12.5 cbox 57,12.5,101,12.5 text 1,10,"Order #",ICFONT, cols=10 text 11,10,"Order Date",ICFONT,cols=9 text 21,10,"Loc Id",ICFONT, cols=10 text 32,10,"Ship Date",ICFONT,cols=10 text 43,10,"Req'd Ship Date",ICFONT,cols=15 text 58,10,"Cust. P/O #",ICFONT,cols=11 text 70,10,"Ship Via",ICFONT, cols=31 text 102,10,"Page #",ICFONT, cols=5 cmove 1,9,MAXCOLS,10,1,11 cfont 2,11,9,11,DBCFONT cfont 11,11,19,11,DBCFONT cfont 21,11,30,11,DBCFONT cfont 32,11,41,11,DBCFONT cfont 43,11,56,11,DBCFONT cfont 58,11,68,11,DBCFONT cfont 70,11,100,11,DBCFONT cfont 102,11,MAXCOLS,11,DBCFONT cfont 58,12,100,12,DBCFONT # address region cbox LEFTCOL,13,MAXCOLS,19,ccols=8::ISHADE 49 57::ISHADE text 1,14,"Ship \nTo:",ICFONT, cols=7 text 50,14,"Sold \nTo:",ICFONT, cols=7 cfont 9,14,49,19,DBFONT cfont 57,14,MAXCOLS,19,DBFONT text 50,16,{custno$},DBFONT, cols=7.5 cmove 16,14,49,19,9,14 cmove 57,14,MAXCOLS,19,59,14 # items cbox LEFTCOL,19,MAXCOLS,63,1,,crows=21::DSHADE, ccols=5 51 57 73 88 text 2,20,"Line",IFONT text 6,20,"Item/Description",IFONT text 52,20,"Units",ICFONT, cols=5 text 58,20,"Qty Ordered",IRFONT,cols=15 text 74,20,"Qty Shipped",IRFONT,cols=14 text 89,20,"Qty Backordered",IRFONT,cols=18 cfont 2,21,4,62,DFONT cfont 6,21,50,62,DFONT cfont 52,21,56,62,DCFONT cfont 58,21,72,62,DBRFONT cfont 74,21,87,62,DBRFONT cfont 89,21,105,62,DRFONT cerase 43,21,47,54 #shade lines shade "~[0-9][0-9][0-9]@2,22,4,58",-.5,0,106,1,DSHADE #bold item numbers font "~[0-9][0-9][0-9]@2,22,4,58",4.5,0,40,0,DBLFONT,9 # watermark - large font with light shading WATERMARK 1,62.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # memo lines font " @1,21,4,55",5,0,90,1,DLFONT # footer text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS text 1,{MAXROWS+.5},{cont$},DBRFONT,cols=MAXRCOLS [SO_PickPackList8.5x11] detect 0,4,"~ [0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9] " detect 0,4,"~ DATEMASK " detect 5,9,"~ [A-Z0-9a-z*]+" detect 5,10,"~ [A-Z0-9a-z]+" # set up document constants local MAXCOLS=80 # max cols to output local MAXRCOLS=79 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local WHSE_COPY=1 local MAX_COPIES=1 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Pick/Pack List - 8.5 x 11" # view in pdf properties prejob { logocols=12,logorows=6 # pick list qty fields are shifted right 1 character more than pack pick=0 for i=24 to 61 if trim(get(51,i,1))<>"" then pick=1;break next i if pick then : doc_title$="PICKING SLIP" else doc_title$="PACKING LIST" endif merge "zMrg get watermark text" # set up copy titles dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then : if pick then : copy_title$[WHSE_COPY]="Warehouse Copy" else copy_title$[WHSE_COPY]="Customer Copy" endif endif # determine if picking list or packing list } prepage { if trim(get(1,7,80))<>"" then : pcopies=WHSE_COPY copy_title$[WHSE_COPY]=trim(get(1,7,80)) endif xcol=0,xrow=0 merge "zMrg get company info" shipto$="" soldto$="" if trim(get(6,9,10))<>"" then : shipto$=trim(get(6,9,10)) endif if trim(get(46,9,10))<>"" then : soldto$=trim(get(46,9,10)) endif # continued? cont$="",sub_line=52 for i=52 to MAXROWS x=pos("(continued"=text$[i]) if x then : cont$="Continued on next page ..." sub_line=55 x$=set(x,i,30,"") break endif next i # add zip barcode xrow=13;xcols=40 #merge "zmrg get zip" } cmove LEFTCOL,1,MAXCOLS,MAXROWS,2,1 # default detail line local BROW=1 local EROW=MAXROWS cfont 2,BROW,4,EROW,DCFONT # line# cfont 6,BROW,25,EROW,DBFONT # item # cfont 27,BROW,31,EROW,DCFONT # uom cfont 33,BROW,38,EROW,DCFONT # bin cfont 40,BROW,52,EROW,DBRFONT # qty ord cfont 54,BROW,66,EROW,DBRFONT # qty ship cfont 68,BROW,MAXRCOLS,EROW,DBRFONT # qty b/o # header section cerase 1,1,MAXCOLS,9 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=9:MBOXSIZE merge "zMrg Form Header" # right header cbox 60,3,RIGHTCOL,7,1,ccols=70::ISHADE,crows=4 5 6 7 text 61,3.5,"Order #",IFONT,cols=9 text 61,4.5,"Order Date",IFONT,cols=9 text 61,5.5,"Batch #",IFONT,cols=9 text 61,6.5,"Page",IFONT,cols=9 text 71,3.5,{trim(cut(51,4,8,""))},DBFONT,cols=9 text 71,4.5,{trim(cut(63,4,8,""))},DBFONT,cols=9 text 71,5.5,{trim(cut(40,4,6,""))},DBFONT,cols=9 text 71,6.5,{trim(cut(74,4,2,""))},DBFONT,cols=9 cbox 60,7,MAXCOLS,9,1,crows=8::ISHADE text 61,7.5,"Customer PO #",ICFONT,cols=19 text 61,8.5,{trim(cut(51,7,25,""))},DBFONT # ship to section cbox LEFTCOL,9,MAXCOLS,19,MBOXSIZE,ccols=6::ISHADE 41 46::ISHADE text 2,10,"Ship",ICFONT,cols=4 text 2,11,"To",ICFONT,cols=4 cfont 7,10,40,17,DBFONT,black text 1,12,{shipto$},DBCFONT,cols=6 # sold to section text 42,10,"Sold",ICFONT,cols=4 text 42,11,"To",ICFONT,cols=4 cfont 47,10,MAXRCOLS,17,DBFONT text 41,12,{soldto$},DBCFONT,cols=6 # zip bar #barcode 41,16,{shipzip$},900,12.0,2 # ribbon section cbox LEFTCOL,19,RIGHTCOL,22,MBOXSIZE,crows=20.5::ISHADE, ccols=7 13 21 44 58 69 text 2,20,"Slsp 1",ICFONT,cols=5 text 8,20,"Slsp 2",ICFONT,cols=5 text 14,20,"Location",ICFONT,cols=7 text 22,20,"Ship Via",ICFONT,cols=22 text 45,20,"Pack List #",ICFONT,cols=13 text 59,20,"Rqstd Ship Date",ICFONT,cols=10 text 70,20,"Actual Ship Date",ICFONT,cols=10 cfont 2,21,6,21,DBCFONT cfont 8,21,12,21,DBCFONT,black cfont 14,21,20,21,DBCFONT cfont 22,21,43,21,DBCFONT cfont 45,21,57,21,DBCFONT cfont 59,21,68,21,DBCFONT cfont 70,21,MAXRCOLS,21,DBCFONT # detail cbox LEFTCOL,22,RIGHTCOL,62,MBOXSIZE, crows=23.5::DSHADE,ccols=5 32 39 53 67 text 2,23,"Line",ICFONT,cols=3 text 6,23,"Item ID",IFONT,cols=21 text 27,23,"U/M",ICFONT,cols=5 text 33,23,"Bin",ICFONT,cols=6 text 40,23,"Ordered",IRFONT,cols=13 text 54,23,"Shipped",IRFONT,cols=13 text 68,23,"Back Ordered",IRFONT,cols=12 # handle memo lines font " @2,24,4,61",4,0,40,1,DFONT,black # memo lines # move for shading cmove 1,24,MAXCOLS,60,1,25 # shade lines shade "~[0-9][0-9][0-9]@2,24,4,61",-.5,0,79,1,DSHADE # watermark - large font with light shading WATERMARK 1,61.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # footer text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS text 1,{MAXROWS+.5},{cont$},DBRFONT,cols=MAXRCOLS cfont 2,63,MAXCOLS,65,IFONT # memo lines [SO_PickPackListLaser] detect 62,4,"~ DATEMASK " detect 6,9,"~ [A-Z0-9a-z*]+" detect 6,10,"~ [A-Z0-9a-z]+" # set up document constants local MAXCOLS=80 # max cols to output local MAXRCOLS=79 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local WHSE_COPY=1 local MAX_COPIES=1 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Pick/Pack List - laser" # view in pdf properties prejob { logocols=12,logorows=6 # pick list qty fields are shifted right 1 character more than pack pick=0 for i=24 to 61 if trim(get(52,i,1))<>"" then pick=1;break next i if pick then doc_title$="PICKING SLIP" else doc_title$="PACKING LIST" merge "zMrg get watermark text" # set up copy titles dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then : if pick then : copy_title$[WHSE_COPY]="Warehouse Copy" else copy_title$[WHSE_COPY]="Customer Copy" endif endif # determine if picking list or packing list } prepage { if trim(get(1,7,50))<>"" then : pcopies=WHSE_COPY copy_title$[WHSE_COPY]=trim(get(1,7,80)) endif xcol=0,xrow=0 merge "zMrg get company info" shipto$="" soldto$="" if trim(get(7,9,10))<>"" then : shipto$=trim(get(7,9,10)) endif if trim(get(47,9,10))<>"" then : soldto$=trim(get(47,9,10)) endif # continued? cont$="",sub_line=52 for i=52 to MAXROWS x=pos("(continued"=text$[i]) if x then : cont$="Continued on next page ..." sub_line=55 x$=set(x,i,30,"") break endif next i } # default detail line local BROW=1 local EROW=MAXROWS cfont 2,BROW,4,EROW,DCFONT # line # cfont 6,BROW,25,EROW,DBFONT # item # cfont 27,BROW,31,EROW,DCFONT # uom cfont 33,BROW,38,EROW,DCFONT # bin cfont 40,BROW,52,EROW,DBRFONT # qty ord cfont 54,BROW,66,EROW,DBRFONT # qty ship cfont 68,BROW,MAXRCOLS,EROW,DBRFONT # qty b/o # header section cerase 1,1,MAXCOLS,9 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=9:MBOXSIZE merge "zMrg Form Header" # right header cbox 60,3,RIGHTCOL,7,1,ccols=70::ISHADE,crows=4 5 6 7 text 61,3.5,"Order #",IFONT,cols=9 text 61,4.5,"Order Date",IFONT,cols=9 text 61,5.5,"Batch #",IFONT,cols=9 text 61,6.5,"Page",IFONT,cols=9 text 71,3.5,{trim(cut(51,4,8,""))},DBFONT,cols=9 text 71,4.5,{trim(cut(63,4,8,""))},DBFONT,cols=9 text 71,5.5,{trim(cut(40,4,6,""))},DBFONT,cols=9 text 71,6.5,{trim(cut(74,4,2,""))},DBFONT,cols=9 cbox 60,7,MAXCOLS,9,1,crows=8::ISHADE text 61,7.5,"Customer PO #",ICFONT,cols=19 text 61,8.5,{trim(cut(51,7,25,""))},DBFONT # ship to section cbox LEFTCOL,9,MAXCOLS,19,MBOXSIZE,ccols=7::ISHADE 41 47::ISHADE text 2,10,"Ship",ICFONT,cols=5 text 2,11,"To:",ICFONT,cols=5 cfont 7,10,40,17,DBFONT,black text 2,12,{shipto$},DBCFONT, cols=5 cmove 7,10,40,17,11,10 # sold to section text 42,10,"Sold",ICFONT,cols=5 text 42,11,"To:",ICFONT,cols=5 cfont 47,10,MAXRCOLS,17,DBFONT text 42,12,{soldto$},DBCFONT,cols=5 cmove 47,10,MAXRCOLS,17,51,10 # ribbon section cbox LEFTCOL,19,RIGHTCOL,22,MBOXSIZE,crows=20.5::ISHADE, ccols=7 13 21 44 58 69 text 2,20,"Slsp 1",ICFONT,cols=5 text 8,20,"Slsp 2",ICFONT,cols=5 text 14,20,"Location",ICFONT,cols=7 text 22,20,"Ship Via",ICFONT,cols=22 text 45,20,"Pack List #",ICFONT,cols=13 text 59,20,"Rqstd Ship Date",ICFONT,cols=10 text 70,20,"Actual Ship Date",ICFONT,cols=10 cfont 2,21,6,21,DBCFONT cfont 8,21,12,21,DBCFONT,black cfont 14,21,20,21,DBCFONT cfont 22,21,43,21,DBCFONT cfont 45,21,57,21,DBCFONT cfont 59,21,68,21,DBCFONT cfont 70,21,MAXRCOLS,21,DBCFONT # detail cbox LEFTCOL,22,RIGHTCOL,62,MBOXSIZE, crows=23.5::DSHADE,ccols=5 32 39 53 67 text 2,23,"Line",ICFONT,cols=3 text 6,23,"Item ID",IFONT,cols=21 text 27,23,"U/M",ICFONT,cols=5 text 33,23,"Bin",ICFONT,cols=6 text 40,23,"Ordered",IRFONT,cols=13 text 54,23,"Shipped",IRFONT,cols=13 text 68,23,"Back Ordered",IRFONT,cols=12 #shade lines shade "~[0-9][0-9][0-9]@2,24,4,57",-.5,0,79,1,DSHADE # handle memo lines font " @2,24,4,61",4,0,40,1,DFONT,black # memo lines # watermark - large font with light shading WATERMARK 1,61.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # footer text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS text 1,{MAXROWS+.5},{cont$},DBRFONT,cols=MAXRCOLS cfont 2,63,MAXCOLS,65,IFONT # memo lines [SO_PickSlipPlain] detect 0,1,"P I C K I N G S L I P" # set up document constants local MAXCOLS=125 # max cols to output local MAXRCOLS=124 # MAXCOLS-1 local LEFTCOL=1 # left vertical line local RIGHTCOL=MAXCOLS # right vertical line local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local WHSE_COPY=1 local MAX_COPIES=1 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Pick Slip - plain" # view in pdf properties prejob { logocols=14,logorows=6 doc_title$="PICKING SLIP" merge "zMrg get watermark text" # set up copy titles dim copy_title$[MAX_COPIES] if MAX_COPIES>=1 then : copy_title$[WHSE_COPY]="Warehouse Copy" endif } prepage { if trim(get(70,2,60))<>"" then : pcopies=WHSE_COPY copy_title$[WHSE_COPY]=trim(get(70,2,60)) endif xcol=31,xrow=2 merge "zMrg get company info" shipto$="" soldto$="" if trim(get(26,12,10))<>"" then : shipto$=trim(cut(26,12,10,"")) endif if trim(get(67,12,10))<>"" then : soldto$=trim(cut(67,12,10,"")) endif # continued? cont$="",sub_line=52 for i=52 to MAXROWS x=pos("(continued"=text$[i]) if x then : cont$="Continued on next page ..." sub_line=55 x$=set(x,i,30,"") break endif next i # add zip barcode xrow=13;xcols=40 #merge "zmrg get zip" } cmove LEFTCOL,1,MAXCOLS,MAXROWS,1,3 # default detail line cbox LEFTCOL,21,RIGHTCOL,64,MBOXSIZE,crows=23::DSHADE,ccols=14 54 65 72 88 107 local BROW=21 local EROW=59 cfont 2,BROW,13,EROW,DCFONT # line # cfont 15,BROW,53,EROW,DFONT # item #/desc cfont 55,BROW,64,EROW,DCFONT # bin cfont 66,BROW,71,EROW,DCFONT # units cfont 73,BROW,87,EROW,DBRFONT # qty ord cfont 89,BROW,106,EROW,DBRFONT # qty ship cfont 108,BROW,MAXRCOLS,EROW,DBRFONT # qty b/o local BROW=22 local EROW=22 cfont 2,BROW,13,EROW,ICFONT # line # cfont 15,BROW,53,EROW,IFONT # item #/desc cfont 55,BROW,64,EROW,ICFONT # bin cfont 66,BROW,71,EROW,ICFONT # units cfont 73,BROW,87,EROW,IRFONT # qty ord cfont 89,BROW,106,EROW,IRFONT # qty ship cfont 108,BROW,MAXRCOLS,EROW,IRFONT # qty b/o # header section cerase 1,1,MAXCOLS,8 cbox LEFTCOL,1,RIGHTCOL,MAXROWS,MBOXSIZE,crows=9:MBOXSIZE merge "zMrg Form Header" # right header cbox 100,5.5,RIGHTCOL,7.5,1,ccols=115::ISHADE,crows=6.5 text 101,6,"Batch No.",IFONT text 116,6,{trim(cut(83,5,6,""))},DBFONT text 101,7,"Picking Slip #",IFONT text 116,7,{trim(cut(107,6,15,""))},DBFONT # ribbon section cbox LEFTCOL,9,RIGHTCOL,12.5,MBOXSIZE,crows=10.5::ISHADE, ccols= 19 34 44 55 72 115 cbox 91,9,115,11.5 cfont 2,10,18,10,ICFONT cfont 20,10,33,10,ICFONT cfont 35,10,43,10,ICFONT cfont 45,10,54,10,ICFONT cfont 56,10,71,10,ICFONT cfont 73,10,90,10,ICFONT cfont 92,10,113,10,ICFONT cfont 115,10,MAXCOLS,10,ICFONT cfont 2,11,18,11,DBCFONT,black cfont 20,11,33,11,DBCFONT,black cfont 35,11,43,11,DBCFONT,black cfont 45,11,54,11,DBCFONT,black cfont 56,11,71,11,DBCFONT,black cfont 73,11,90,11,DBCFONT,black cfont 73,12,113,12,DBFONT,black cfont 92,11,113,11,DBCFONT,black cfont 115,11,MAXCOLS,11,DBCFONT,black # ship to section cbox LEFTCOL,12.5,MAXCOLS,21,MBOXSIZE,ccols=10::ISHADE 57 66::ISHADE text 2,14,{trim(cut(17,13,8,""))},ICFONT,cols=8 text 11,14,{mcut(26,13,30,5,"","Y","Y")},DBFONT text 2,15,{shipto$},DBFONT # sold to section text 58,14,{trim(cut(58,13,8,""))},ICFONT,cols=8 text 67,14,{mcut(67,13,30,5,"","Y","Y")},DBFONT text 58,15,{soldto$},DBFONT # zip bar #barcode 41,16,{shipzip$},900,12.0,2 # shade lines shade "~[0-9][0-9][0-9]@11,24,13,59",-9.5,0,124,1,DSHADE # bold item numbers font "~[0-9][0-9][0-9]@11,24,13,59",3,0,35,1,DBFONT # watermark - large font with light shading WATERMARK 1,63.5,{doc_title$},cgtimes,120,shade=WATERMARK_SHADE,center,cols=MAXCOLS,fit,spacing=.75 # footer text 1,{MAXROWS+.5},{copy_title$[copy]},DBCFONT,cols=MAXCOLS text 1,{MAXROWS+.5},{cont$},DBRFONT,cols=MAXRCOLS cfont 2,63,MAXCOLS,65,IFONT # memo lines [Generic] # This rule set will set columns & rows and # enhance the hdg for all other reports # requires UnForm 5 detect 0,1,"~(PAGE)|(Page)" # set up document constants local MAXCOLS=250 # max cols to output local MAXROWS=66 # max rows to output cols MAXCOLS # max output columns rows MAXROWS # max output rows local MAX_COPIES=1 pcopies MAX_COPIES portrait dpi 600 # see global constant above GSON # graphical shading title "Generic" # view in pdf properties prepage { maxlen=80 # min columns is 80 for i=1 to MAXROWS if len(cvs(text$[i],2))>maxlen then : maxlen=len(cvs(text$[i],2)) endif next i cols$=str(maxlen+1) # load row 1 variables rptdate$=trim(get(1,1,10)) x=pos("PAGE"=text$[1]) if x=0 then x=pos("Page"=text$[1]) pageno$=trim(get(x,1,11)) compname$=trim(get(21,1,x-1-20)) x$=set(1,1,200,"") # load row 2 variables time$=trim(get(1,2,10)) x=pos("AM"=time$) if x=0 then x=pos("PM"=time$) if x=0 then : left2$=trim(get(1,2,20)) time$="" endif title$=trim(get(21,2,100)) x$=set(1,2,200,"") # load row 3 variables if time$="" then time$=trim(get(1,3,10)) subtitle$=trim(get(21,3,100)) x$=set(1,3,200,"") # Now draw box around header exec("cbox 1,.5,"+cols$+",3.75,MBOXSIZE,HSHADE") # now place line 1 headers that need justification x$="text 1,1.25,"+$22$+compname$+$22$+ ",HBCFONT,14,cols="+str(maxlen) exec(x$) x$="text 1,1.25,"+$22$+pageno$+$22$+ ",HBRFONT,cols="+str(maxlen) exec(x$) # now place line 2 headers that need justification x$="text 1,2.25,"+$22$+title$+$22$+ ",HBCFONT,12,cols="+str(maxlen) exec(x$) # now place line 3 headers that need justification x$="text 1,3.25,"+$22$+subtitle$+$22$+ ",HBCFONT,cols="+str(maxlen) exec(x$) } text 2,1.25,{rptdate$},HBFONT text 2,2.25,{time$},HBFONT text 2,3.25,{left2$},HBFONT font "~(End of Report)|(END OF REPORT)",0,0,13,1,HBFONT [zMrg Form Header] LOGO_IMAGE 1,1,{logocols},{logorows},"COMP_LOGO" text 1,2.25,{doc_title$},HBRFONT,16,cols=MAXRCOLS text 1,3.25,{reprint$},HRFONT,12,cols=MAXRCOLS text 1,2.25,{comp_name$},HBCFONT,14,cols=MAXRCOLS text 1,3.25,{comp_addr1$},HCFONT,12,cols=MAXRCOLS text 1,4.25,{comp_addr2$},HCFONT,12,cols=MAXRCOLS text 1,5.25,{comp_addr3$},HCFONT,12,cols=MAXRCOLS text 1,6.25,"COMP_PHONES",HCFONT,12,cols=MAXRCOLS text 1,7.25,"COMP_EMAIL",HCFONT,cols=MAXRCOLS text 1,8.25,"COMP_WEBSITE",HCFONT,cols=MAXRCOLS [zMrg get company info] if xcol>0 and xrow>0 and trim(get(xcol,xrow,40))<>"" then : comp_name$=trim(get(xcol,xrow,40)) comp_addr1$=trim(get(xcol,xrow+1,40)) comp_addr2$=trim(get(xcol,xrow+2,40)) comp_addr3$=trim(get(xcol,xrow+3,40)) endif if xcol=0 or xrow=0 or trim(get(xcol,xrow,40))="" then : comp_name$="COMP_NAME" comp_addr1$="COMP_ADDR1" comp_addr2$="COMP_ADDR2" comp_addr3$="COMP_ADDR3" endif [zMrg get watermark text] wmlines=1,wdoc_title$="",xdoc_title$=trim(doc_title$) watermark_loop: x=pos(" "=xdoc_title$) if x=0 then if wdoc_title$="" then wdoc_title$=xdoc_title$ else wdoc_title$=wdoc_title$+$0a$+trim(xdoc_title$) fi; goto end_watermark_loop if wdoc_title$="" then wdoc_title$=trim(xdoc_title$(1,x)) else wdoc_title$=wdoc_title$+$0a$+trim(xdoc_title$(1,x)) xdoc_title$=trim(xdoc_title$(x+1)) wmlines=wmlines+1 goto watermark_loop end_watermark_loop: [zMrg get zip] shipzip$="" # Retrieve the zip code from either xrow or xrow-1 #x=mask(left(text$[xrow],xcols),"[0-9][0-9][0-9][0-9][0-9]") if x>0 then shipzip$=get(x,xrow,10,1) #if x=0 then x=mask(trim(left(text$[xrow-1],xcols)),"[0-9][0-9][0-9][0-9][0-9]") if x=0 then x=mask(left(text$[xrow-1],xcols),"[0-9][0-9][0-9][0-9][0-9]") if shipzip$="" then if x>0 then shipzip$=get(x,xrow-1,10,1) shipzip$=sub(shipzip$,"-","") [zMrg load rpt header] rptdate$=trim(get(1,1,10)) x=pos(" Page "=text$[1]) compname$=trim(get(20,1,x-1-20)) pageno$=trim(get(x,1,20)) time$=trim(get(1,2,8)) title$=trim(get(20,2,150)) opt1$=trim(get(20,3,150)) if brow>=4 then opt2$=trim(get(20,4,150)) if brow>=5 then opt3$=trim(get(20,5,150)) if brow>=6 then opt4$=trim(get(20,6,150)) [zMrg Report Header] cerase 1,1,MAXCOLS,{brow} cbox LEFTCOL,.5,RIGHTCOL,{brow+1.25},MBOXSIZE,HSHADE text 2,1.5,{rptdate$},HFONT,black text 2,2.5,{time$},HFONT,black text 1,1.5,{pageno$},HRFONT,cols=MAXRCOLS,black text 1,1.5,{compname$},HBCFONT,14,cols=MAXCOLS,black text 1,2.75,{title$},HBCFONT,12,cols=MAXCOLS,black text 1,3.69,{opt1$},HCFONT,9,cols=MAXCOLS,black text 1,4.88,{opt2$},HCFONT,9,cols=MAXCOLS,black text 1,5.82,{opt3$},HCFONT,9,cols=MAXCOLS,black text 1,6.75,{opt4$},HCFONT,9,cols=MAXCOLS,black [zMrg Report Header 2] cerase 1,1,MAXCOLS,{brow} cbox LEFTCOL,.5,RIGHTCOL,{brow+1.25},MBOXSIZE,HSHADE text 2,1.5,{rptdate$},HFONT,black text 2,2.5,{time$},HFONT,black text 1,1.5,{pageno$},HRFONT,cols=MAXRCOLS,black text 1,1.5,{compname$},HBCFONT,14,cols=MAXCOLS,black text 1,2.82,{title$},HBCFONT,12,cols=MAXCOLS,black text 1,3.95,{opt1$},HCFONT,9,cols=MAXCOLS,black text 1,4.87,{opt2$},HCFONT,9,cols=MAXCOLS,black text 1,5.72,{opt3$},HCFONT,9,cols=MAXCOLS,black text 1,6.65,{opt4$},HCFONT,9,cols=MAXCOLS,black