![]() |
#2
yuyunliuhen2007-06-09 14:02
|
如何判断打开的文件里的没有记录呢?
即是说这个文件是空的该如何判断
比如:
ifstream in("file.txt");
if(in)
cerr<<"error to open";
if(该文件为空)
cout<<"该文件中没有记录!";
如何判断打开的文件里的没有记录呢?
即是说这个文件是空的该如何判断
比如:
ifstream in("file.txt");
if(in)
cerr<<"error to open";
if(该文件为空)
cout<<"该文件中没有记录!";
![]() |
#2
yuyunliuhen2007-06-09 14:02
|
![]() |
#3
bill88882007-06-09 19:53
|
![]() |
#4
wfpb2007-06-10 16:33
|
![]() |
#5
bill88882007-06-21 00:02
|
![]() |
#6
wnmbccn2007-06-21 00:09
|