Merge branch 'master' of http://dd-vmp07-com04:3000/AppStd/Monorepo
This commit is contained in:
commit
d17504af4d
@ -40,17 +40,22 @@ 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
|
||||||
|
Try
|
||||||
Using oInputStream As New FileStream(txtIDBFOPath.Text, FileMode.Open)
|
Using oInputStream As New FileStream(txtIDBFOPath.Text, FileMode.Open)
|
||||||
Dim oContents(oInputStream.Length) As Byte
|
Dim oContents(oInputStream.Length) As Byte
|
||||||
oInputStream.Read(oContents, 0, oInputStream.Length)
|
oInputStream.Read(oContents, 0, oInputStream.Length)
|
||||||
|
|
||||||
' convert string to stream
|
' convert string to stream
|
||||||
Using oMemoryStream As New MemoryStream(oContents)
|
Using oMemoryStream As New MemoryStream(oContents)
|
||||||
Using oFileStream As New FileStream("d:\file.txt", FileMode.Create, FileAccess.Write)
|
Using oFileStream As New FileStream("d:\file.pdf", FileMode.Create, FileAccess.Write)
|
||||||
oMemoryStream.WriteTo(oFileStream)
|
oMemoryStream.WriteTo(oFileStream)
|
||||||
End Using
|
End Using
|
||||||
End Using
|
End Using
|
||||||
End Using
|
End Using
|
||||||
|
|
||||||
|
Catch ex As Exception
|
||||||
|
MsgBox(ex.Message, MsgBoxStyle.Critical)
|
||||||
|
End Try
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
End Class
|
End Class
|
||||||
Loading…
x
Reference in New Issue
Block a user