View Single Post
Join Date: Jan 2008
Posts: 119
Reputation: kux is on a distinguished road 
Solved Threads: 10
kux kux is offline Offline
Junior Poster

Re: formated file reading problem

 
0
  #3
Feb 7th, 2008
Originally Posted by Passmark View Post
I don't think it is supported. A replacement might be fscanf() + some extra code, but it really depends on what you are doing with with vfscanf.
hmmm, what i am doing is that i want to wrap my formated file read in a File class that i design myself so that it throws exceptions for every problem that might occur.
what i want to is to have a Scan method in my File class that looks like

void File:can ( const char * Format, ... )
{
va_list objArgs;
va_start( objArgs, pcFormat );
vfscanf( m_pFile, pcFormat, objArgs ); // m_pFile is the file handle
va_end( objArgs );
}

this is actually wraping fscanf in File:can
Reply With Quote