Main Menu

HOME

.Net
ASP
Assembly
C
C++
Delphi
HTML
Java
JavaScript
MySQL
PC interface
Powershell
Perl
PHP
VBScript
Visual Basic
XML

US Job listings




   Misc

   Amazon

   Links

File Error Handling Functions


 

Error Handling Functions

The clearerr function

#include <stdio.h>
void clearerr(FILE *stream);

The clearerr function clears the end-of-file and error indicators for the stream pointed to by stream.

The feof function

#include <stdio.h>
int feof(FILE *stream);

The feof function tests the end-of-file indicator for the stream pointed to by stream and returns nonzero if and only if the end-of-file indicator is set for stream, otherwise it returns zero.

The ferror function

#include <stdio.h>
int ferror(FILE *stream);

The ferror function tests the error indicator for the stream pointed to by stream and returns nonzero if and only if the error indicator is set for stream, otherwise it returns zero.

The perror function

#include <stdio.h>
void perror(const char *s);

The perror function maps the error number in the integer expression errno to an error message. It writes a sequence of characters to the standard error stream thus: first, if s is not a null pointer and the character pointed to by s is not the null character, the string pointed to by s followed by a colon (:) and a space; then an appropriate error message string followed by a new-line character. The contents of the error message are the same as those returned by the strerror function with the argument errno, which are implementation-defined.

 

All text is available under the terms of the GNU Free Documentation License
Source : Wikibooks

 

 

 



 




   Sponsors
 

   Software
500 Java Tips E-book
PHP editor
PERL editor
Beginning Java
Beginning Visual Basic
Learn VB.net
Learn VB 6
VB and databases
ASP image library
C++ builder programming
C++ fundamentals

   Source Code
Create a file(VB)
display disk drive properties(Powershell)
display information about shares on your computer(VBScript)
A to Z links(PHP)
displays a list of My Computer locations(VBScript)
list all databases(php)
increase / decrease number with a button press(Javascript)
List all files in a directory(VBnet)




Copyright © 2004 by programmershelp.co.uk