Freigeben über


CFile::GetPosition

Obtains the current value of the file pointer, which can be used in subsequent calls to Seek.

virtual ULONGLONG GetPosition( ) const;

Return Value

The file pointer.

Example

CFile cfile;
cfile.Open(_T("Seek_File.dat"), CFile::modeCreate |
   CFile::modeReadWrite);
LONGLONG lOffset = 1000;
ULONGLONG lActual;
lActual = cfile.Seek(lOffset, CFile::begin);
ASSERT(cfile.GetPosition() == lActual);

Requirements

Header: afx.h

See Also

Concepts

CFile Class

CFile Members

Hierarchy Chart