title: Opening file for reading in COBOL
body: <p>I'm using <a href="https://github.com/OpenCobolIDE/OpenCobolIDE/" rel="nofollow">OpenCobolIDE</a> 4.7.4 (it's based on GnuCOBOL) on Windows 10 and trying to compile this program opening a file for reading:</p>
  
  <pre><code>   IDENTIFICATION DIVISION.
     PROGRAM-ID. HELLO.
  
     ENVIRONMENT DIVISION.
        INPUT-OUTPUT SECTION.
           FILE-CONTROL.
           SELECT STUDENT ASSIGN TO 'input.txt'
           ORGANIZATION IS LINE SEQUENTIAL.            
  
     DATA DIVISION.
        FILE SECTION.
        FD STUDENT.
        01 STUDENT-FILE.
           05 STUDENT-ID PIC 9(5).
           05 NAME PIC A(25).
  
        WORKING-STORAGE SECTION.
        01 WS-STUDENT.
           05 WS-STUDENT-ID PIC 9(5).
           05 WS-NAME PIC A(25).
        01 WS-EOF PIC A(1). 
  
     PROCEDURE DIVISION.
        OPEN INPUT STUDENT.
           PERFORM UNTIL WS-EOF='Y'
           READ STUDENT INTO WS-STUDENT
              AT END MOVE 'Y' TO WS-EOF
              NOT AT END DISPLAY WS-STUDENT
           END-READ
           END-PERFORM.
        CLOSE STUDENT.
     STOP RUN.
  </code></pre>
  
  <p>The <em>input.txt</em> is in the same directory as the source coude, yet I'm still getting the following error:</p>
  
  <pre><code>Main.cob:24: libcob: File does not exist (STATUS = 35) File : 'input.txt'
  </code></pre>
  
  <p>What am I doing wrong?</p>