Re: why the content is NULL that I read file??

From: gangadhar npk (gangadhar_npk__at_nospam.plz)
Date: 04/28/04


Date: Wed, 28 Apr 2004 22:55:42 +0530

hi,
   Shldnt the code be something like this ?
CString pFile = *str;
You never seemed to set the value to the pFile.
hth
gangadhar

terrcy wrote:

> to ALL:
> void GetOfforLenth(CFile &file, const CString *str, int index,LONG
> &offset,LONG &lenth)
> {
> int nstart,nend;
> CString pfile;
> file.Read(&pfile,file.GetLength());
> ///why the pfile is null
> offset=nstart=pfile.Find(str[index]);
> nend=pfile.Find(str[index+1]);
> pfile=pfile.Mid(nstart,nend-nstart);
> lenth=pfile.GetLength();
> }
>
> it is appreciated for anyone reply
>
>



Relevant Pages