	SUBROUTINE FIXFRM(SA0,FILE)
	INTEGER*2 SA0(4),FILE(4),PC(256),ICNT(256)
	ICH1=IGETC()
	ICH2=IGETC()
	IL=LOOKUP(ICH1,SA0)
	IF(IL.LT.1) STOP '? - FIXFRM-CANNOT FIND SAVE AREA 0'
	IL=LOOKUP(ICH2,FILE)
	IF(IL.LT.1) STOP '? - FIXFRM-CANNOT FIND NEW FILE'
	IR=IREADW(256,ICNT,0,ICH1)
	N1=36
	DO 25 I=1,4
25	ICNT(I)=FILE(I)
	SUM=0.0
	MAX=0
	MIN=32000
	DO 2 M=1,16
	MM=M
	IR=IREADW(256,PC,N1,ICH2)
	IW=IWRITW(256,PC,MM,ICH1)
	DO 1 I=1,256
	IF(PC(I).GT.MAX) MAX=PC(I)
	IF(PC(I).LT.MIN) MIN=PC(I)
	A=PC(I)
1	SUM=SUM+A
2	N1=N1+1
	ICNT(69)=3
	ICNT(74)=2
	ICNT(75)=19
	ICNT(76)=0
	ICNT(77)=35
	ICNT(78)=18
	ICNT(79)=1
	ICNT(80)=19
	ICNT(104)=2
	ICNT(112)=18
	ICNT(87)=MAX
	ICNT(88)=MIN
	ICNT(89)=RDPR(SUM)
	ICNT(91)=SUM/4096.0
C	ICNT(184) = 0
	IW=IWRITW(256,ICNT,0,ICH1)
	CALL CLOSEC(ICH2)
	CALL IFREEC(ICH2)
	CALL CLOSEC(ICH1)
	CALL IFREEC(ICH1)
	RETURN
	END
