image of READY prompt

Wang2200.org

Listing of file='ACCT030B' on disk='vmedia/701-2607C.wvd.zip'

# Sector 5, program filename = 'ACCT030B'
0010 REM ACCT030B, RELEASE 2.0, (06/01/79) THIS PROGRAM IS A COPYRIGHT PRODUCT
      OF WANG LABORATORIES INC. UNAUTHORIZED REPRODUCTION OR USE IS PROHIBITED
0170 COM K,K(6,L9),K$(L9)5,K1,K1$Q0,K2,K7$L8
   : DIM K5$L8,K8$1,K9$1
   : DIM P8$5,P9$1
   : GOTO 4000
4000 SELECT @PARTS0$
   : IF A6$="B"THEN 4390
   : GOSUB '100(" ",HEX(7F),Q0,0,"ENTER CUSTOMER ID (RETURN = SAME CUSTOMER, O
     R END)",2)
   : IF Q6$=" "THEN Q6$=K1$
   : IF Q6$<>"END"AND Q6$<>"end"AND Q6$<>HEX(1F)THEN 4100
   : A6$="C"
   : STR(M5$,8)="A"
   : LOAD TM5$4000,
4100 GOSUB '96(1)
   : K1$=Q6$
   : GOSUB '232(1,1,K1$)
   : GOSUB '91
   : IF J0=3OR J0=7THEN 4000
   : IF J0>0THEN 6580
   : GOSUB '50(5," ")
   : PRINT AT(1,0,)
   : K,K1,K2=0
   : K$()=" "
   : MAT K=ZER
   : J1=1
   : GOSUB 7050
   : GOSUB '100("Y,N","YyY Nn",1,1,"IS CUSTOMER ID OK  (Y OR N)",2)
   : IF Q6$<>"Y"THEN 4000
   : GOSUB '100("0","9999999",7,0,"ENTER CHECK NO.",1)
   : K1=Q9
4290 Q$(1)="0"
   : IF P3$="1"THEN Q$(1)="0.01"
   : GOSUB '100(Q$(1),"999999.99",6,2,"ENTER CHECK AMOUNT",1)
   : K2=Q9
   : GOSUB 7100
   : IF P3$="1"THEN 5830
   : K=K2
   : GOSUB 7160
   : J1=0
4390 GOSUB '100("-2","99999999",8,0,"ENTER INVOICE NO.  (-2=END OF CHECK, -1=R
     EVIEW, 0=GEN'L PAYMENT)",1)
   : IF Q6$=HEX(1F)THEN Q9=-2
   : A6$=" "
   : I9=Q9
   : K9$=" "
   : J1=J1+1
   : IF J1<=L9THEN 4500
   : PRINT AT(8,0,)
   : K$()=" "
   : MAT K=ZER
   : J1=1
4500 IF I9<0THEN 5690
   : IF I9>0THEN 4570
   : K(5,J1)=K
   : K(1,J1)=0
   : GOTO 5880
4570 K(1,J1)=I9
   : GOSUB 7200
   : $PACK(F=L2$)K7$FROMK1$,K(1,J1),"0","00"
   : K5$=STR(K7$,,Q0+4)
   : PRINT AT(1,0);"** Accumulating invoice balance **"
4630 IF J0=7THEN GOSUB '254
   : GOSUB '232(2,0,K7$)
   : IF Q$="N"THEN 4910
   : GOSUB '91
   : IF J0=7THEN 4630
   : IF J0>0THEN 6580
   : GOSUB '51(3,Q)
4700 IF K9$="Y"THEN 4840
   : IF C(Q)<K(1,J1)THEN 4840
   : IF C(Q)>K(1,J1)THEN 4790
   : K9$="Y"
   : IF F$(Q)="0"OR F$(Q)="2"THEN 4840
   : K9$="C"
   : IF F$(Q)="3"OR F$(Q)="4"THEN 4840
   : K9$=" "
   : GOTO 4840
4790 PRINT AT(3,0,80);HEX(07);"Invoice no. not on file."
   : K(2,J1)=0
   : J1=J1-1
   : GOTO 4390
4840 ON VAL(F$(Q))-47GOTO 4850,4870,4850,4890,4890
4850 K(2,J1)=K(2,J1)+A(Q)-A1(Q)-A2(Q)
   : GOTO 4910
4870 K(2,J1)=K(2,J1)-A1(Q)-A2(Q)
   : GOTO 4910
4890 K(2,J1)=K(2,J1)-A(Q)
4910 IF J0=7THEN GOSUB '254
   : GOSUB '237(2,1)
   : IF Q$="E"THEN 5020
   : GOSUB '91
   : IF J0=7THEN 4910
   : IF J0>0THEN 6580
   : GOSUB '51(3,Q)
   : IF STR(K5$,,Q0+4)=STR(O$(Q),,Q0+4)THEN 4700
   : Q6$=" "
   : IF K9$="C"THEN GOSUB '100("Y,N","YyNn",1,1,"DO YOU WISH TO APPLY A CREDIT
      MEMO (OR CREDIT INVOICE)",2)
5020 IF K9$=" "OR Q6$="N"THEN 4790
5030 GOSUB 7200
5050 IF K9$="C"THEN GOSUB '100("0","999999.99",6,2,"ENTER CREDIT AMOUNT TO APP
     LY",1)
   : ELSE GOSUB '100("-1","999999.99",6,2,"ENTER PAYMENT AMOUNT  (-1 = DISPUTE
     /CLEAR DISPUTE)",1)
   : IF Q9=-1THEN 5250
   : IF K9$="C"THEN Q9=-Q9
   : IF Q9<=KTHEN 5120
   : PRINT AT(3,0,80);HEX(07);"Payment amount > unapplied amount."
   : GOTO 5050
5120 K(5,J1)=Q9
   : K=K-Q9
   : GOSUB 7160
   : GOSUB 7200
   : IF K(2,J1)<=K(5,J1)THEN 5210
   : K(3,J1)=0
   : IF .02*K(2,J1)<K(2,J1)-K(5,J1)THEN 5210
   : K(3,J1)=K(2,J1)-K(5,J1)
5210 K(6,J1)=K(2,J1)-K(3,J1)-K(4,J1)-K(5,J1)
   : GOSUB 7200
   : GOTO 5920
5250 GOSUB '100("C,D","CcDd",1,1,"ENTER DISPUTE OPTION (D=DISPUTE, C=CLEAR DIS
     PUTE)",2)
   : K8$=Q6$
   : $PACK(F=L2$)K7$FROMK1$,K(1,J1),"0","00"
   : K5$=STR(K7$,,Q0+5)
5300 IF J0=7THEN GOSUB '254
   : GOSUB '232(2,1,K7$)
   : J$(3)=" "
   : GOSUB '91
   : IF J0=7THEN 5300
   : IF J0<>3THEN 5420
5370 IF J0=7THEN GOSUB '254
   : GOSUB '237(2,1)
   : IF Q$="E"THEN 5460
   : GOSUB '91
   : IF J0=7THEN 5370
5420 IF J0>0THEN 6580
   : GOSUB '51(3,Q)
   : IF STR(K5$,,Q0+5)=STR(O$(Q),,Q0+5)THEN 5490
5460 PRINT AT(3,0,80);HEX(07);"Invoice no. not found."
   : GOTO 5030
5490 IF K8$="D"THEN 5550
   : IF C$(Q)="D"THEN 5550
   : PRINT AT(3,0,80);HEX(07);"Record not disputed."
   : GOSUB '238(2)
   : GOTO 5030
5550 DBACKSPACE #3,1S
   : C$(Q)=Q6$
   : K$(J1)="DISP"
   : IF K8$="C"THEN K$(J1)="CLEAR"
   : GOSUB 7200
   : GOSUB '41(3,Q)
   : GOSUB '238(2)
   : O6=K(1,J1)
   : O7=0
   : P8$=K$(J1)
   : GOSUB 7720
   : GOTO 4390
5690 STR(M5$,8)="C"
   : IF I9=-1THEN LOAD TM5$4000,
   : IF K=0THEN 6380
   : GOSUB '100("A,I,D","AaIiDd",1,1,"ENTER A = APPLY TO GENERAL PAYMENT, I =
     ANOTHER INVOICE NO., D = DROP",2)
   : K(1,J1)=0
   : IF Q6$="D"THEN 6380
   : J1=J1-1
   : IF Q6$="I"THEN 4390
   : J1=J1+1
   : K(5,J1)=K
   : GOTO 5880
5830 J1=1
   : K(5,J1)=K2
   : K(2,J1)=B
   : K(6,J1)=K(2,J1)-K(5,J1)
5880 K=0
   : GOSUB 7160
   : GOSUB 7200
5920 GOSUB '100("Y,N","YyY Nn",1,1,"ENTER DISCOUNT/ALLOWANCE  (Y OR N)",2)
   : IF Q6$="N"THEN 6060
   : GOSUB '100("-9999.99","9999.99",4,2,"ENTER DISCOUNT AMOUNT",1)
   : K(3,J1)=Q9
   : K(6,J1)=0
   : IF P3$="1"OR K(1,J1)>0THEN K(6,J1)=K(2,J1)-K(3,J1)-K(5,J1)
   : GOSUB 7200
6010 GOSUB '100("-9999.99","9999.99",4,2,"ENTER ALLOWANCE AMOUNT",1)
   : K(4,J1)=Q9
   : K(6,J1)=0
   : IF P3$="1"OR K(1,J1)>0THEN K(6,J1)=K(2,J1)-K(3,J1)-K(4,J1)-K(5,J1)
6060 Q6$="OVER    PART"
   : K$(J1)=STR(Q6$,(SGN(K(6,J1))+1)*4+1,4)
   : GOSUB 7200
   : IF K(6,J1)>=0THEN 6220
   : GOSUB '100("Y,N","YyY Nn",1,1,"ACCEPT OVERPAYMENT  (Y OR N)",2)
   : IF Q6$="Y"THEN 6220
   : K=K+K(5,J1)
   : K$(J1)=" "
   : K(3,J1),K(4,J1),K(5,J1),K(6,J1)=0
   : GOSUB 7160
   : GOSUB 7200
   : IF P3$="1"THEN 6380
   : GOTO 5050
6220 GOSUB '100("Y,N","YyY Nn",1,1,"IS ENTRY LINE OK  (Y OR N)",2)
   : IF Q6$="Y"THEN 6360
   : K$(J1)=" "
   : K=K+K(5,J1)
   : GOSUB 7160
   : FOR Q9=1TO 6
   : K(Q9,J1)=0
   : NEXT Q9
   : PRINT AT(7+J1,0,80)
   : J1=J1-1
   : IF P3$="0"THEN 4390
   : GOTO 4000
6360 IF ABS(K(3,J1))+ABS(K(4,J1))+ABS(K(5,J1))>0THEN GOSUB 7340
   : IF P3$="0"AND K>0THEN 4390
6380 DBACKSPACE #5,1S
   : B=B-F6
   : P5=I6
   : IF F6>0THEN P4=I6
   : GOSUB '40(5," ")
   : GOSUB '238(1)
   : P6=F6
   : P7=F7
   : P8=F8
   : P9=F9
   : E6=E6+F6
   : E7=E7+F7
   : E8=E8+F8
   : E9=E9+F9
   : P9$="T"
   : A1$="CHECK TOTAL"
   : GOSUB 7720
   : F6,F7,F8,F9=0
   : GOTO 4000
6580 DEFFN'31
   : A6$="E"
   : STR(M5$,8)="A"
   : LOAD TM5$4000,
7010 %######.##-
7020 %#,###.##-
7030 %###,###.##-
7050 PRINT AT(4,0);"CUST ID";TAB(8);K1$;TAB(9+Q0);A1$
   : IF P3$="1"THEN PRINT "BALANCE FORWARD";TAB(20);
   : ELSE PRINT "OPEN ITEM BALANCE";TAB(20);
   : PRINTUSING 7030,B
   : RETURN
7100 PRINT AT(4,37);"CHECK NO.";TAB(47);K1;TAB(58);"CHECK AMT";TAB(68);
   : PRINTUSING 7030,K2
   : PRINT AT(6,26);"* * E N T R Y   M O D E * *"
   : PRINT "INV. NO.";TAB(12);"OLD BAL";TAB(26);"DISC";TAB(36);"ALLOW";TAB(47)
     ;"PAYMENT";TAB(60);"NEW BAL";TAB(72);"REMARKS"
   : RETURN
7160 PRINT AT(5,54);"UNAPPLIED AMT";TAB(68);
   : PRINTUSING 7030,K
   : RETURN
7200 PRINT AT(7+J1,0,0)
   : PRINTUSING "######## ",K(1,J1);
   : PRINTUSING 7030,K(2,J1);
   : PRINT TAB(22);
   : PRINTUSING 7020,K(3,J1);
   : PRINT TAB(33);
   : PRINTUSING 7020,K(4,J1);
   : PRINT TAB(44);
   : PRINTUSING 7030,K(5,J1);
   : PRINT TAB(57);
   : PRINTUSING 7030,K(6,J1);
   : PRINT TAB(72);K$(J1)
   : RETURN
7340 J=0
   : Q6$="1"
   : IF K(5,J1)<0THEN Q6$="2"
   : $PACK(F=L2$)K7$FROMK1$,K(1,J1),Q6$
7380 CONVERT JTO STR(K7$,Q0+6),(##)
   : GOSUB '233(2,1,K7$,0)
   : J=J+1
   : IF J>99THEN Q$="S"
   : IF Q$="D"THEN 7380
   : GOSUB '91
   : IF J0>0THEN 6580
   : C1$(Q)=STR(K7$,,Q0)
   : F$(Q)=STR(K7$,Q0+5)
   : H$(Q)=STR(K7$,Q0+6)
   : O6,C(Q)=K(1,J1)
   : A$(Q)="0"
   : C$(Q)=" "
   : D1(Q)=I6
   : O7,C1(Q)=K1
   : A(Q),A2(Q),D(Q)=0
   : A1(Q)=K(3,J1)+K(4,J1)
7570 IF K(5,J1)>0THEN A2(Q)=K(5,J1)
   : IF K(5,J1)<0THEN A(Q)=-K(5,J1)
   : P7=K(3,J1)
   : P8=K(4,J1)
   : P9=K(5,J1)
   : P6=P7+P8+P9
   : P8$=K$(J1)
   : F6=F6+P6
   : F7=F7+P7
   : F8=F8+P8
   : F9=F9+P9
   : GOSUB '41(3,Q)
   : GOSUB '238(2)
7720 $PACK(F=L1$)N1$(G0)FROMK1$,A1$,O6,O7,P6,P7,P8,P9,P8$,P9$
   : O6,O7,P6,P7,P8,P9=0
   : P8$,P9$=" "
   : G0=G0+1
   : IF G0<5THEN RETURN
   : MAT REDIM N1$(5)49
   : GOSUB '48(6)
   : MAT REDIM N1$(4)61
   : N1$()=ALL(FF)
   : G0=1
   : IF Q9<.95THEN RETURN
   : GOSUB '254
   : GOTO 6580
9998 DEFFN'29"Q$=";HEX(22);"ACCT030B";HEX(22);":SCRATCH TQ$:SAVET$()Q$";HEX(0D
     )
9999 DEFFN'30"DIM Z$57:IF STR(I0$,,1)=HEX(20)THENI0$=HEX(323135):Z$=";HEX(22);
     "GBS/MVP - Enter cash receipts.";HEX(22);":SELECT#15<I0$>:$OPEN#15:SELECT
     LIST<I0$>(132): LIST Z$:LIST Z$#:LIST Z$V:LIST Z$':$CLOSE#15:SELECTLIST00
     5(80)";HEX(0D)