ToStream
<Extension()> _ Public Function ToStream(ByVal Source As String) As System.IO.MemoryStream Dim Bytes() As Byte = System.Text.Encoding.ASCII.GetBytes(Source) Return New System.IO.MemoryStream(Bytes) End FunctionExample:
Dim MyStream as Stream = "Fred".ToStream
Description
Returns a stream when given a string
Details
- Author: Rory Becker
- Submitted on: 2/7/2011 8:55:39 PM
- Language: VB
- Type: System.String
- Views: 1979
Double click on the code to select all.