Memory Mapped File Length

徘徊边缘 提交于 2019-12-05 09:15:24

You can't append to a string in the stream by writing more character after it, as that won't change the length of the string already written.

Also, there is no method of the BinaryWriter that lets you write to a specific position in the stream like that. For the overload that takes a character array and two integers, the second parameter specifies the position in the array, not the position in the stream.

If you want to change the string written in the stream, you have to read the string from the stream and rewrite the stream with the new string.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!