try& catch Server Connection with Processing
in
Programming Questions
•
3 years ago
Hi,
I'm working on an Processing project, where I send data via the network to another Processing running machine. The problem is, when the second (server) machine isnt running, the first machine (client) crashes, because he cant connect to the server.
As far as I know, I need to do a try & catch. So if he can't connect to the server, he waits a bit, tries it again...
I never done something like this before, and as far as I searched for it here, I haven't found a valuable solution.
So, anyone can help me on this topic?
I'm using the Network library, and I try to connect to the server like this:
c = new Client(this, "192.168.10.22", 12345);
Thanks for any help!
Greetings
Nicolas
1