Tipo così:
codice:
int lastpos;
while(!in.eof())
{
	lastpos = in.tellg()-1;
	in.ignore(80, '\n');
	in.ignore();
	cout << lastpos << " " << in.tellg() << "\n";
}
in.seekg(0, ios::beg);
in.sync();
while(in.tellg()!=lastpos)
{
        //codice
}