-
I have written a chat app using winsock with tcp protocol. I have no problems transfering text back and forth between the two apps.
I have Two picture boxs on the form (image1 and image2) in the image one box you can load a picture from your hard drive into it. I want the user to be able to send that picture to image2 on the other users app. I have tried everything. When I try to send the pictures like I did the text I get errors, cant find file, object needed. I'm not sure but I think I'm sending the file but I cant parse it from the strings. I dunno I could be wrong, anyway , if someone has the almighty answer I would greatly appreciate it.
Thanx,
Todd
-
When sending files, you should read the file in binary mode, use Get to read the file into a variable, then on the receiving end using Put to write the data into the file.
Sunny
-
IP Troubles
Hi,
I also had a problem like that once, and I knew what was wrong. Here is what I tested with to know what went wrong. If you use the Winsock's data arrival and send method exactly like all your other send \ receive objects(textboxes,etc.), all the data will be sent together and received together. Liek mine was 2 picture boxes. You pick a color and send it to another picture box. BUT then I added a check box on the client + server and when I sent a color with the hex number above &H00000 the check box was either checked or unchecked and when I sent checbox values the pictureboxes turned black.
So do the stuff seperately.
I hope this helps....