home *** CD-ROM | disk | FTP | other *** search
- 1 rem c. by elcomp publishing inc. 1983
- 5 rem approval given to wozniak by elcomp to use this program
- 10 rem business invoice program--don't use punctuations on customer input info
- 100 rem modified for individual usage-by e.s.wozniak-load "bus inv",8
- 110 open 1,4
- 180 print"[147]"
- 190 input"enter tax rate (%)";tr:tr=tr/100
- 200 input"enter date";rd$
- 220 input"enter first invoice no.";i1
- 250 input"enter account no. (0=end)";c1
- 260 if c1=0 then 1600
- 270 sc=1:dc=1:d=0:v=0
- 280 input"discount yes(1) no(0)";dc
- 290 input"shipping autom. added yes(1) no(0)";sc
- 300 if sc=0 then input"how much?";v
- 310 input"customers order no.";co$
- 320 input"name of customer";s1$
- 340 input"number and street";s2$
- 360 input"city*state*zip-code";s3$
- 370 print
- 380 input"1=30 days net,2=cod,3=prepaid";te
- 390 if te=1 then te$="30 days net"
- 400 if te=2 then te$="c o d"
- 410 if te=3 then te$="prepaid"
- 420 print:print"1=forwarder,2=united parcel":input"3=parcel post";sv
- 430 if sv=1 then sv$="forwarder"
- 440 if sv=2 then sv$="united parcel"
- 450 if sv=3 then sv$="parcel post"
- 460 print"[147]":prints1$:prints2$:prints3$
- 470 print:input"ship to same address";q$
- 480 if q$="y" then 510
- 490 print:input"name";h1$:input"no.and str.";h2$:input"c.,st.,zip";h3$
- 500 goto520
- 510 h1$=s1$:h2$=s2$:h3$=s3$
- 520 for q=1 to 3:print#1:next q
- 530 print#1,tab(29);"elcomp publishing inc."
- 540 print#1,tab(28);"2174 w. foothill blvd. #e"
- 550 print#1,tab(32);"upland, ca. 91786"
- 555 print#1,tab(34);"714-623-8314"
- 560 print#1:print#1:print#1
- 565 print#1,spc(55);rd$
- 570 print#1
- 575 print#1,spc(3);"account #:";c1;spc(25);"invoice #:";i1
- 580 print#1:print#1
- 585 print#1,tab(3);"sold to:-";tab(32);"ship to:-"
- 590 print#1,spc(6);s1$;spc(41-len(s1$));h1$
- 600 print#1,spc(6);s2$;spc(41-len(s2$));h2$
- 610 print#1,spc(6);s3$;spc(41-len(s3$));h3$
- 620 print#1:print#1
- 625 for a=1 to 80:print#1,chr$(163);:next
- 630 print#1,spc(3);"your order";spc(12);"terms";spc(15);"shipped via";
- 631 print#1,spc(8);"date shipped"
- 640 print#1,spc(3);co$;spc(22-len(co$));te$;spc(20-len(te$));sv$;
- 642 print#1,spc(19-len(sv$));rd$
- 645 for a=1 to 80:print#1,chr$(184);:next
- 650 print#1,spc(3);"order";spc(2);"ship";spc(12);"description";
- 651 print#1,spc(17);"price";spc(11);"total"
- 655 for a=1 to 80:print#1,chr$(163);:next
- 660 print"[147]":gosub 1130
- 670 gosub 830
- 680 goto 660
- 690 s1=i
- 700 if dc=0 then 740
- 710 if (s1>0) and (s1<30) then d=.25
- 720 if (s1>31)and (s1<60) then d=.33
- 730 if s1>60 then d=.4
- 740 if v<>0 then 800
- 750 if s1<15 then v=2
- 760 if (s1>14) and (s1<30) then v=1.25
- 770 if (s1>29) and (s1<50) then v=1.5
- 780 if (s1>49) and (s1<100) then v=2
- 790 if s1>99 then v=2.5
- 800 i1=i1+1
- 810 r=int(d*100+.5):r$=str$(r)
- 820 goto 940
- 830 a=o:gosub 1410
- 840 g$=d$:l1=l
- 850 c=s1*o
- 860 a=c:gosub 1410
- 870 j$=str$(n1):k$=str$(s1):kk$=str$(z1)
- 880 j=len(j$):k=len(k$):kk=len(kk$)
- 890 print#1,spc(5-kk);z1;
- 900 print#1,spc(6-k);s1;spc(8);n1;spc(6-j);e$;
- 910 print#1,spc(30-len(e$)-l1);g$;spc(17-l);d$
- 920 c=s1*o:t=t+c
- 930 return
- 940 d1=d*t
- 950 d1=int(d1*100+.5)/100
- 960 print#1
- 970 a=d1:gosub 1410
- 980 print#1,spc(46-len(r$));r;spc(2);"%discount= -";spc(14-l);d$
- 990 for p=1 to (10-zs):print#1:next p
- 1000 print#1,spc(23);"thank you for your order"
- 1003 for a=1 to 80:print#1,chr$(184);:next
- 1005 print#1,spc(3);"net";spc(5);"sales";spc(52);"invoice"
- 1006 print#1,spc(3);"am't";spc(4);"tax";spc(5);"freight";spc(42);"total"
- 1007 for a=1 to 80:print#1,chr$(163);:next
- 1020 a=t-d1:gosub 1410
- 1030 g$=d$:l1=l
- 1040 a=v:gosub 1410
- 1050 h$=d$
- 1060 m1=(t-d1+v)*tr:rem to exclude sales tax on freight use m1=(t-d1)*tr
- 1070 a=t-d1+m1+v:gosub 1410
- 1080 j$=d$:l2=l
- 1090 a=m1:gosub 1410
- 1100 print#1,spc(8-l1);g$;spc(7-l);d$;spc(3);h$;spc(51-l2);j$
- 1105 for a=1 to 80:print#1,chr$(184);:next
- 1110 print#1:print#1
- 1120 gosub 1290:i=0:t=0:goto 250
- 1130 input"which item no.";n1
- 1150 if n1=0 then 690
- 1160 restore
- 1170 read n,e$,o
- 1180 if n=0 then 1210
- 1190 if n=n1 then 1230
- 1200 goto 1170
- 1210 print"item no. not found !"
- 1220 print:print:print:goto 1130
- 1230 input"enter quantity ordered ";z1
- 1250 input"enter quantity shipped ";s1
- 1270 i=i+s1:zs=zs+1
- 1280 return
- 1290 print#1,spc(3);"from:->";tab(45);"remarks:-"
- 1298 print#1
- 1300 print#1,spc(5);"elcomp publishing inc."
- 1310 print#1,spc(5);"2174 w. foothill blvd. #e"
- 1320 print#1,spc(5);"upland, ca. 91786"
- 1330 for zv=1 to 3:print#1
- 1340 next zv
- 1345 print#1,spc(3);"to:->"
- 1348 print#1
- 1350 print#1,spc(5);h1$
- 1360 print#1,spc(5);h2$
- 1370 print#1,spc(5);h3$
- 1380 print"[147]"
- 1390 zs=0:s1=0:t=0:i=0
- 1400 return
- 1405 rem decimal align subroutine
- 1410 k1$="0"
- 1420 k2$=".00"
- 1430 b=int(a*100+.5)/100
- 1440 d1$=str$(b)
- 1450 d0=b*10
- 1460 d2=int(d0)
- 1470 d3=d0-d2
- 1480 if d3<.09 then 1510
- 1490 d$=d1$
- 1500 goto 1570
- 1510 d4=int(b)
- 1520 d5=b-d4
- 1530 if d5<.09 then 1560
- 1540 d$=d1$+k1$
- 1550 goto 1570
- 1560 d$=d1$+k2$
- 1570 l=len(d$)
- 1580 return
- 1600 close1:end
- 2000 rem data statements start here for product stock # and unit price
- 2010 data 100,product no.1,2.25
- 2020 data 200,product no.2,1.50
- 2030 data 300,product no.3,3.75
- 2040 data 400,product no.4,2.50
- 2050 data 0,0,0
- 2060 rem last statement has to contain 0,0,0
-