home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CP/M
/
CPM_CDROM.iso
/
mbug
/
mbug073.arc
/
GENELOGY.LBR
/
FAHNCHRT.CMD
< prev
next >
Wrap
OS/2 REXX Batch file
|
1979-12-31
|
2KB
|
87 lines
* FAHNCHRT.CMD for an Ahnentafel Forebears chart
ERASE
IF myprnt = 'Y'
SET PRINT ON
?? ' '
?? CHR(27)+'E'
SET MARGIN TO 8
ENDIF
STORE '000' TO n
STORE 0 TO fath,moth
STORE 1 TO page
STORE t TO nomore
STORE f TO male
STORE '------------------------' TO dash
GO VAL(mno)
STORE 'AHNENTAFEL CHART for '+TRIM(firstnms)+' '+surname TO header
? header+$(STR(0,80),1,62-LEN(header))+"Printed "+date()
?
? "Notes: b. = born, d. =died, m. = married, * = baptism,;
c. = circa"+$(STR(0,10),1,6)+"Page "+STR(page,1)
?
? dash+dash+dash+$(dash,1,6)
RELEASE header
STORE 5 TO lines
STORE n+str(#,4) TO n
STORE ' 1. ' TO idnumb
do fahnprnt
release mno
?
? dash+' PARENTS '+dash+$(dash,1,21)
STORE lines+2 TO lines
STORE 1 TO a,b
DO fahnloop
IF nomore
RETURN
ENDIF
? dash+' GRAND PARENTS '+dash+$(dash,1,15)
STORE lines+2 TO lines
STORE t TO nomore
STORE 2 TO a,b
DO fahnloop
IF nomore
RETURN
ENDIF
? dash+' GREAT GRAND PARENTS '+dash+$(dash,1,9)
STORE lines+2 TO lines
STORE t TO nomore
STORE 4 TO a,b
DO fahnloop
IF nomore
RETURN
ENDIF
? dash+' GREAT GREAT GRAND PARENTS '+dash+$(dash,1,3)
STORE lines+2 TO lines
STORE t TO nomore
STORE 8 TO a,b
DO fahnloop
IF nomore
RETURN
ENDIF
? dash+' GREAT GREAT GREAT GRAND PARENTS '+$(dash,1,21)
STORE lines+2 TO lines
STORE 16 TO a,b
DO WHILE a < 2*b
DO CASE
CASE $(n,4*a,4) <> '0000'
GO val($(n,4*a,4))
STORE STR(#,4) TO subj
IF fath> 0
GO fath
STORE STR(2*a,2)+'. ' TO idnumb
STORE t TO male
DO fahnprnt
ENDIF
GO &subj
IF moth > 0
GO moth
STORE STR(2*a+1,2)+'. ' TO idnumb
DO fahnprnt
ENDIF
OTHERWISE
ENDCASE
STORE a+1 TO a
ENDDO
?
RETURN