无法倒退C#中的文本文件 [英] can not rewind a text file in c#
本文介绍了无法倒退C#中的文本文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有文本文件(myfile.txt),它有10行字符串,我成功读取了所有字符串.我想再次读取它
该文件是由FileStream和StreamReader(c#)创建的
我找不到倒带或fseek(...,SEEK_SET,0L)之类的命令
I have text file(myfile.txt) it has 10 rows of strings,i read all strings successfully.I want to read it againe
the file was created by FileStream and StreamReader (c#)
i could not find command such as rewind or fseek(...,SEEK_SET,0L)
推荐答案
它只是FileStream.Seek
.
http://msdn.microsoft.com/en-us/library/system. io.filestream.seek.aspx [ ^ ]
祝你好运!
It''s justFileStream.Seek
.
http://msdn.microsoft.com/en-us/library/system.io.filestream.seek.aspx[^]
Good luck!
这篇关于无法倒退C#中的文本文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文