       IDENTIFICATION DIVISION.
        PROGRAM-ID.oefening-12a.
        AUTHOR.YANNIS-DE-WOLF.
        DATE-WRITTEN.ERGENS-IN-OKTOBER.

       ENVIRONMENT DIVISION.
        CONFIGURATION SECTION.
        SOURCE-COMPUTER.PC.
        OBJECT-COMPUTER.PC.

        Input-output section.
           file-control.
               select cdbestand
                 assign to "toeta.dat"
                 organization sequential
                 access sequential
                 file status cd-status.

       DATA DIVISION.
        file section.
           FD cdbestand.
           01 c-cdrecord.
               03 c-nummer pic x(5).
               03 c-titel pic x(20).
               03 c-uitvoerder pic x(20).
               03 c-aantal pic 99.
               03 c-genre pic x(15).
               03 c-prijs pic 9(6).
               03 c-releasedatum pic 99/99/99.

        WORKING-STORAGE SECTION.
        77 cd-status pic xx.
           88 eof-cd value '10'.
        01 i-cdrecord.
           02 i-nummer pic x(5).
           02 i-titel pic x(20).
           02 i-uitvoerder pic x(20).
           02 i-aantal pic 99.
           02 i-genre pic x(15).
           02 i-prijs pic 9(6).
           02 i-releasedatum pic 99/99/99.
        77 antwoord pic x.
           88 stoppen value "n","N".
        screen section.
        copy "Oef12.txt".

       PROCEDURE DIVISION.
       Oefening12.
        perform B-prog
        perform Body
        perform E-prog
      / Stop run
        Exit program
        .

        B-prog.
        Open extend cdbestand
        move "j" to Antwoord
        .

        Body.
        Perform VI-Rec-MO-Scherm1-MO-CDrec
        until Antwoord = "N" or "n".

        VI-Rec-MO-Scherm1-MO-CDrec.
        display spaces upon crt
        display G-Oef12
        accept I-nummer line 9 col 40  with required
        accept i-titel line 10 col 40  with required
        accept i-uitvoerder line 11 col 40  with required
        accept i-aantal line 12 col 40                    with required
        accept i-genre line 13 col 40                     with required
        accept i-prijs line 14 col 40            with required
        accept i-releasedatum line 15 col 40     with required
        move i-cdrecord to c-cdrecord
        write c-cdrecord end-write
        accept antwoord line 18 col 50
        .

        e-prog.
        close cdbestand.
