With a TcpClient this would be very simple:to send the contents of an image file or, if you already have an Image object:vb.net Code:
myTcpClient.GetStream().Write(IO.File.ReadAllBytes("file path here"))If you're going to use .NET then you should use .NET. If you're going to cling to the VB6 way of doing things then you may as well stick with VB6.vb.net Code:
myImage.Save(myTcpClient.GetStream(), ImageFormat.Jpeg)




Reply With Quote