totn C Functions

C Language: ftell function
(Determine File Position)

In the C Programming Language, the ftell function returns the current file position indicator for the stream pointed to by stream.

Syntax

The syntax for the ftell function in the C Language is:

long int ftell(FILE *stream);

Parameters or Arguments

stream
The stream whose file position indicator is to be returned.

Returns

The ftell function returns the current file position indicator for stream. If an error occurs, the ftell function will return -1L and update errno.

Required Header

In the C Language, the required header for the ftell function is:

#include <stdio.h>

Applies To

In the C Language, the ftell function can be used in the following versions:

  • ANSI/ISO 9899-1990

Similar Functions

Other C functions that are similar to the ftell function:

See Also

Other C functions that are noteworthy when dealing with the ftell function: