Hi,
When I stream a text file as an attachment, the result is an
email with an incomplete attachment. Is there something
wrong with the code below? Thanks.
Dim iosStream As New System.IO.MemoryStream
Dim iosStream2 As System.IO.Stream
Dim sWriter As System.IO.StreamWriter = New System.IO.StreamWriter(iosStream)
sWriter.Write(myAttach.txtData)
iosStream.Position = 0
Dim test As New OpenSmtp.Mail.Attachment(iosStream, myAttach.FileName)
.AddAttachment(test)