ENVIRONMENT DIVISION.
INPUT-OUTPUT SECTION.
SELECT OUTPUT-FILE ASSIGN TO OUTPUT-FILE-ID
FILE STATUS IS OUTPUT-RETURN-CODE
ACCESS MODE IS SEQUENTIAL
ORGANIZATION IS LINE SEQUENTIAL.
DATA DIVISION.
FILE SECTION.
FD OUTPUT-FILE.
01 OUTPUT-RECORD PIC X(72).
WORKING-STORAGE SECTION.
01 OUTPUT-PARAMETERS.
02 OUTPUT-RETURN-CODE PIC X(02).
02 OUTPUT-FILE-ID PIC X(12).
01 CERT-TBL.
02 FILLER PIC X(36) VALUE "<html><head><title>COBOL Webler Cert".
02 FILLER PIC X(36) VALUE "ification</title> ".
02 FILLER PIC X(36) VALUE "<style type='text/css'> ".
02 FILLER PIC X(36) VALUE " ".
02 FILLER PIC X(36) VALUE "h2 {font-family: 'Monotype Corsiva',".
02 FILLER PIC X(36) VALUE "'Brush Script MT','cursive'} ".
02 FILLER PIC X(36) VALUE "</style></head><body><div align='cen".
02 FILLER PIC X(36) VALUE "ter'><br /><br /> ".
02 FILLER PIC X(36) VALUE "<h1>This is to Certify that</h1><u><".
02 FILLER PIC X(36) VALUE "h2> ".
02 C-NAME PIC X(72) VALUE "Your Name ".
02 FILLER PIC X(36) VALUE "</h2></u><h3>has acheived the status".
02 FILLER PIC X(36) VALUE " of Master COBOL Webler</h3> ".
02 FILLER PIC X(36) VALUE "</div></body></html> ".
02 FILLER PIC X(36) VALUE " ".
01 FILLER REDEFINES CERT-TBL.
02 CERT-TBL-ENTRY PIC X(72) OCCURS 008 INDEXED BY CERT-TBL-IDX.
PROCEDURE DIVISION.
ACCEPT C-NAME FROM COMMAND-LINE.
MOVE "certify.htm" TO OUTPUT-FILE-ID.
OPEN OUTPUT OUTPUT-FILE.
PERFORM
VARYING CERT-TBL-IDX FROM 1 BY 1
UNTIL CERT-TBL-IDX GREATER THAN 8
MOVE CERT-TBL-ENTRY (CERT-TBL-IDX) TO OUTPUT-RECORD
WRITE OUTPUT-RECORD
END-PERFORM.
CLOSE OUTPUT-FILE.
GOBACK.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.