What I\'m trying to do is to send a JFrame through sockets. The problem is after I send the form and press the button to view it I get the below exception.
I did it something similar years ago and I ended up sending a JPanel
instead that a frame itself.
I think that the problem in this situation is the fact that the frame is somewhat attached to a Graphics
which is not, of course, serialized and sent over network becuse it's really near to the host OS in the implementation (at AWT Window
level)
I suggest you to try sending just a panel (which in the end is just the content pane of the frame that you are trying to send) a try again. If you really need to attach frame properties you could encapsulate them in a custom object and attach them by serialization (eg title or whatever).