Dart.Ftp Namespace > TcpBase Class : State Property |
Public ReadOnly Property State As ConnectionState
Dim instance As TcpBase Dim value As ConnectionState value = instance.State
public ConnectionState State {get;}
public: property ConnectionState State { ConnectionState get(); }
private void myComponent_StateChanged(object sender, EventArgs e) { if (myComponent.State == ConnectionState.Closed) this.Text = "Not Connected"; else if (myComponent.State == ConnectionState.Connected) this.Text = "Connected to " + myComponent.RemoteEndPoint.ToString(); else this.Text = "Securely connected to " + myComponent.RemoteEndPoint.ToString(); }
Private Sub myComponent_StateChanged(ByVal sender As Object, ByVal e As EventArgs) If myComponent.State = ConnectionState.Closed Then Me.Text = "Not Connected" ElseIf myComponent.State = ConnectionState.Connected Then Me.Text = "Connected to " & myComponent.RemoteEndPoint.ToString() Else Me.Text = "Securely connected to " & myComponent.RemoteEndPoint.ToString() End If End Sub