	REMARK	*********************************\
		*  P/R260.BAS  ABSENTEE REPORT  *\
		*    3/16/79           2:45 PM  *\
		*********************************
%INCLUDE CURSOR
	DIM G2$(5),G3(5)
	DIM S(96),R$(5),R1(2),R2(5),B1(5)
	GOTO 6000
%INCLUDE SUBS1
%INCLUDE GENINFO
%INCLUDE MSTRIN
825	A1=44								REMARK  ****    LINE PRINTER ROUTINE    ****

	IF LINE.COUNT% < 55 THEN RETURN					REMARK  IF SPACE REMAINS ON REPORT PAGE, RETURN
	P=P+1
	PRINT CHR$(12);
830	PRINT TAB((A1-LEN(G2$(1)))/2);G2$(1);TAB(A1);"DATE ";		REMARK  PRINT COMPANY NAME AND DATE
	X0=G3(1):GOSUB 680.5
	PRINT
	PRINT TAB((A1-LEN(X4$))/2);X4$;TAB(A1);"PAGE ";P		REMARK  PRINT REPORT TITLE AND PAGE NUMBER
	PRINT
835	PRINT" EMPLOYEE  NAME";TAB(35);"HRS SHORT"
	PRINT
	LINE.COUNT%=6							REMARK  SET LINE COUNTER FOR NEW REPORT PAGE
	RETURN 
6000	DEF FNR(Z1)=INT(Z1*100+.5)/100
	MASKA$=" ######    /23456789.123456789.123/ ####.##"		REMARK  SET UP PRINT MASK
	MASKB$="####.##"
	PRINT CLEAR.SCREEN$;"P/R ABSENTEE REPORT"
	PRINT "KEY RETURN TO BEGIN; CTRL-C TO EXIT"
6000.1	IF CONSTAT%=0 THEN GOTO 6000.1 ELSE A%=CONCHAR%			REMARK  POLL KEYBOARD FOR <RETURN> OR CTRL-C
	IF A%=03H THEN GOTO 6200					REMARK  TERMINATE PROGRAM IF CTRL-C PRESSED
	IF A% <> 0DH THEN GOTO 6000.1					REMARK  WAIT FOR <RETURN> TO BE PRESSED
	Y9=2:OPEN "G/I0F010.DAT" RECL 200 AS Y9
	GOSUB 700							REMARK  READ GENERAL INFORMATION FILE
	LPRINTER							REMARK  SELECT PRINTER AS OUTPUT DEVICE
	OPEN "P/R0F110.DAT" RECL 1150 AS 1				REMARK  OPEN EMPLOYEE MASTER FILE
	OPEN "P/R0F050.DAT" AS 3					REMARK  OPEN SUMMARY FILE FOR SUBSEQUENT DELETION
	X4$="ABSENTEE REPORT"
	LINE.COUNT%=60
	FOR J%=1 TO MSTR.RECORDS					REMARK  USE THE ENTIRE MASTER FILE
	X0=J%
	GOSUB 745							REMARK  READ EMPLOYEE RECORD
	Z1=S(73)+S(75)+S(77)+S(80)					REMARK  ADD UP TOTAL HOURS FOR CURRENT EMPLOYEE
	IF R2(1)=1 AND Z1<80 \						REMARK IF AN HOURLY EMPLOYEE HAS LESS THAN 80 HOURS
	THEN \
	LINE.COUNT%=LINE.COUNT%+1:\					REMARK PRINT DETAIL ON THE REPORT
 	GOSUB 825:\
	PRINT USING MASKA$;S(1);R$(1);80-Z1:\
	A=A+(80-Z1)							REMARK  ADD TO TOTAL HOURS SHORT
	NEXT J%
	PRINT
	PRINT " TOTAL";TAB(37);
	PRINT USING MASKB$;A						REMARK  PRINT TOTAL HOURS SHORT
	DELETE 3:CREATE "P/R0F050.DAT" AS 3				REMARK  DELETE AND RECREATE SUMMARY FILE
6200	CONSOLE
	PRINT CLEAR.SCREEN$;"P/R ABSENTEE REPORT LOADING MENU"		REMARK  EXIT PROGRAM AND LOAD MENU
	CHAIN "P/R000"

