Click here to Skip to main content
15,911,524 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I have two forms in single windows Application and picturebox in each form. How to transfer image from picturebox in form1 to picturebox in form2 using TCP help with solution.

Thanks in advance
Posted
Updated 14-Feb-13 3:35am
v2
Comments
Chris Reynolds (UK) 14-Feb-13 10:08am    
Is there a reason you want to do this using TCP as there are other, simpler, ways

1 solution

Soooo.....first, you're NOT going to get a ready made solution for this as you're transport method in the same application is utterly ridiculous and WAY TOO MUCH work for something so simple to do.

You're saying you want to implement a TCP server and client in the same application just so you can stop yourself from doing this:
Dim form2 As New Form2
form2.SetPictureBoxImage(PictureBox1.Image)

and in Form2...
Public Sub SetPictureBoxImage(image As Bitmap)
    PictureBox2.Image = image
End Sub
 
Share this answer
 
Comments
Thomas Daniels 14-Feb-13 12:25pm    
My 5!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900