For your case, you can either check for ssConnected and ssConnecting, or simply watch OnError and OnConnect events.
OnError will trigger when there's a problem with connecting to the server (like your case with bad address), OnConnect will trigger only when you successfully established the connection.
Using the TLSocket.SocketState is a bit more advanced, but you shouldn't need to use them.
Hope this helps.