User Tools

Site Tools


Sidebar

Programming Reference/Librarys

Question & Answer

Q&A is closed







c:keywords:file

FILE

 FILE Pointer (stream)
 shows on a given file
 
 The data type FILE is a structure that contains information about a file
 or specified data stream. It includes such information as a file descriptor,
 current position, status flags, and more. It is most often used as a pointer
 to a file type, as file I/O functions predominantly take pointers as
 parameters, not the structures themselves (see example below).

C Sourcecode Example

#include <stdio.h> /* including standard library */
//#include <windows.h> /* uncomment this for Windows */
 
 
int main (void)
{
    FILE *filestream;
 
    filestream=fopen("test.txt","r");
 
    if (filestream == NULL)
        perror("cannot open file");
 
    fclose(filestream);
    return 0;
}

on the occasion of the current invasion of Russia in Ukraine

Russian Stop this War
c/keywords/file.txt · Last modified: 2024/02/16 01:05 (external edit)

Impressum Datenschutz