1. First, the server enables the listener.
Serversocket1-> Port = strtoint (5000 );
Serversocket1-> active = true;
The serversocket1 control responds to the serversocket1listen event;
2. Create a connection
Clientsocket1-> address = "127.0.0.1 ";
Clientsocket1-> Port = strtoint (5000 );
Clientsocket1-> active = true;
The clientsocket1 control first responds to the clientsocket1lookup event;
Clientsocket1 control, and then the corresponding clientsocket1ing ing event; (if an error occurs during connection to the server, the clientsocket1error event is handled ).
The clientsocket1 control then responds to the clientsocket1connect event;
The serversocket1 control responds to the serversocket1getsocket event;
The serversocket1 control responds to the serversocket1acceptt event;
The clientsocket1 control then responds to the clientsocket1write event;
3. The client sends
The serversocket1 control responds to the serversocket1clientread event. In this event, the Service sends authentication to the customer, which is received by the clientsocket1read event.
4. Event Description:
The clientsocket1 control, the clientsocket1read event receives the information sent back by the Service.
The clientsocket1 control then responds to the clientsocket1write event;