ns
This commit is contained in:
parent
635d5f5f94
commit
02630aa1da
@ -39,12 +39,13 @@ Public Class frmtest
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub Button4_Click(sender As Object, e As EventArgs) Handles Button4.Click
|
Private Sub Button4_Click(sender As Object, e As EventArgs) Handles Button4.Click
|
||||||
Dim memString As String = "Memory test string !!!"
|
|
||||||
' convert string to stream
|
Dim oStream As New FileStream(txtIDBFOPath.Text, FileMode.Open)
|
||||||
Dim buffer As Byte() = Encoding.ASCII.GetBytes(memString)
|
Dim oContents(oStream.Length) As Byte
|
||||||
Dim ms As New MemoryStream(buffer)
|
|
||||||
|
Dim ms As New MemoryStream(oContents)
|
||||||
'write to file
|
'write to file
|
||||||
Dim file As New FileStream("d:\file.txt", FileMode.Create, FileAccess.Write)
|
Dim file As New FileStream("e:\file.pdf", FileMode.Create, FileAccess.Write)
|
||||||
ms.WriteTo(file)
|
ms.WriteTo(file)
|
||||||
file.Close()
|
file.Close()
|
||||||
ms.Close()
|
ms.Close()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user