|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
truncate fileHello,
I have a 4 GB file and I want to truncate it to, say, 3.8. Cany I do something like seek to some byte in the file and then delete all the bytes that come after that? If yes how? Thanks <leibnizs***@gmail.com> wrote:
> if anyone cares, I used interop with the function: You didn't need to do that. Just use FileStream.SetLength.> SetEndOfFile() -- Jon Skeet - <sk***@pobox.com> http://www.pobox.com/~skeet Blog: http://www.msmvps.com/jon.skeet If replying to the group, please do not mail me too |
|||||||||||||||||||||||