[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
FPUTC
. Summary
fputc(int <c>, int <fh>);
. Description
The fputc function writes a character to the file indicated by the
file handle <fh>. <c> is the character to write.
. Return Value
The character written is returned, unless there is an error, in
which case a value of -1 is returned.
. Example
int f, i;
str teststr[] = "This is a test string";
f = fopen("test.dat", "w");
for (i = 0; i < 21; ++i) // write out string to file
fputc(subchr(teststr, i), f); // character by character
See Also:
fgetc
fputs
fwrite
ASCII table
fgets
fread
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson