Gets a value which indicates if a connection to the remote host has been established.
Returns true if the connection has been established; otherwise returns false.
The IsConnected property can only be used to indicate if there is still a logical connection to the remote host. It cannot be used to detect abnormal conditions such as the remote host aborting the connection, the physical network connection being lost or other critical errors.