client side
fileee.Copy("D:\Image.gif", "D:\Image.txt")
read the file and save it to a string
Dim sr As System.IO.StreamReader ****
sr = System.IO.File.OpenText("D:\Image.txt")
Dim mNameArray As String read into an string
Dim x As String
x = sr.Read()
mNameArray = x
sr.Close()
SendData("PICTURE|" & x) sends the data to the host
server side (located in the OnLineReceived Sub)
Case "PICTURE"
SendToClients("PIC|" & dataArray(1), sender)
UpdateStatus(dataArray(1))
now back to the client (under the proccess comands sub...)
Case "PIC"
Dim oFile As System.IO.File
Dim oWrite As System.IO.StreamWriter
oWrite = oFile.CreateText("D:\DavidBackup\Vb.net Projects\Helper\Client\Images\Recieved.txt")
oWrite.Write(dataArray(1))
fileee.Copy("D:\DavidBackup\Vb.net Projects\Helper\Client\Images\Recieved.txt", "D:\DavidBackup\Vb.net Projects\Helper\Client\Images\Recieved.gif")
PictureBox1.Image.FromFile("D:\DavidBackup\Vb.net Projects\Helper\Client\Images\Recieved.gif")