Send feedback on this topic.
Teradata.Client.Provider
StateChange Event



Teradata.Client.Provider Namespace > TdConnection Class : StateChange Event
Occurs when the state of the TdConnection changes.
Syntax
'Declaration
 
Public Event StateChange As StateChangeEventHandler
'Usage
 
Dim instance As TdConnection
Dim handler As StateChangeEventHandler
 
AddHandler instance.StateChange, handler
public event StateChangeEventHandler StateChange
public:
event StateChangeEventHandler^ StateChange
Event Data

The event handler receives an argument of type StateChangeEventArgs containing data related to this event. The following StateChangeEventArgs properties provide information specific to this event.

PropertyDescription
Gets the new state of the connection. The connection object will be in the new state already when the event is fired.  
Gets the original state of the connection.  
Remarks

The StateChange event is raised immediately during the following transitions:

  1. When a connection is opened the state transitions from Closed to Open.
  2. When a connection transitions from Open to Closed during connection closure.
Requirements

Target Platforms: Windows 8.1, Windows 10, Windows Server 2012 R2, Windows Server 2016, Windows Server 2019

See Also