メモリストリームをチャンクで読み取るのに問題があります。
Dim ByteBuffer(4096) As Byte
While ProcessedBytes < FileLength
BytesRead = MemoryStream.Read(ByteBuffer, 0, 4096)
'Write the buffer to an output stream
ProcessedBytes += BytesRead
End While
'MemoryStream.Read(ByteBuffer、0、4096)'は常にゼロを返します。'MemoryStream.Length'を見ましたが、ストリームには間違いなくいくつかのバイトが含まれています。