标题:关于文本文件的度取
只看楼主
qingcheng
Rank: 1
等 级:新手上路
帖 子:1
专家分:0
注 册:2007-2-1
 问题点数:0 回复次数:0 
关于文本文件的度取

大家好 ,小弟最近有个问题
我要写一个读txt文件的函数,这个方法很多.但是呢,我要读的文本文件太大了7M多.所以根本读不出来.
大家看看我的方法,给点建议:
char s[255];
FILE *stream;
m_list.ResetContent();
stream = fopen("e:\\123.txt", "r");
if (stream != NULL)
{

while (!feof(stream)){
fscanf(stream,"%s\t",s);
m_list.AddString(s);
AfxMessageBox(s);
}
fclose(stream);
}
谢谢.

搜索更多相关主题的帖子: 文本文件 stream list txt 
2007-04-10 13:21



参与讨论请移步原网站贴子:https://bbs.bccn.net/thread-130703-1-1.html




关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 1.126493 second(s), 7 queries.
Copyright©2004-2025, BCCN.NET, All Rights Reserved