Method DisconnectAsync
DisconnectAsync()
Closes the connection to a service.
Declaration
public Task DisconnectAsync()
Returns
Type | Description |
---|---|
Task | A Task that represents the asynchronous disconnect operation. |
Remarks
Use this method to explicitly disconnect from a data source. When this method completes, the ConnectionStatus is set to Disconnected or Failed.
If this method is called when a data source has a ConnectionStatus of Connecting, the current connection attempt is cancelled.
Applies to
Platforms and versions
Target | Versions |
---|---|
.NET Standard 2.0 | 200.2 |
.NET 6.0 | 200.2 |
.NET 6.0 Windows | 200.2 |
.NET 6.0 Android | 200.2 |
.NET 6.0 iOS | 200.2 |
.NET Framework | 200.2 |
UWP | 200.2 |