c#|C#中如何将字符串转换成流,同时如何将流转换成字符串()

MemoryStreamfileStream=newMemoryStream();
StreamWriterouterstr=newStreamWriter(fileStream);
stringstr= "hehehehe ";
outerstr.Write(str);
outerstr.Flush();

    推荐阅读