The file is socket server.
The file communicates with the client through socket.
The first step is to create socket and waiting for the client to connect. (I have to click run)
The second step is to receive the messages from the client after the connection, , and then to run the model for 100 seconds. (I have to click run to receive the message and run the model)
The third step is to send the entire table of numbers (results)to the client.(I have to click run)
Finally, close the socket.(I have to click run)
Once I run the code(The first step), subsequent actions will be executed automatically without clicking run. This is my question.
In other words.
Waiting for the client to connect and automatically receiving the client messages, after running the code(the first step), and automatically running the model for 100 seconds, and automatically sending the results to the client, and finally, closing socket automatically.