开发者

Read binary file from a position in ASP.NET

I want to read a binary file from a particular position. I am u开发者_C百科sing the following code but that is not working.

FileStream fs = new FileStream(filepath, FileMode.Open, FileAccess.Read);
fs.Seek(len,SeekOrigin.Current);
int bytesRead = fs.Read(buf, 0, buf.Length);

It starts reading from beginning.


fs.Seek(len,SeekOrigin.Begin);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜