OpenWithNewPasswordAsync(string, CancellationToken)

This method opens a new connection asynchronously with a new password and token that can cancel the task.

Declaration

// C#
public Task OpenWithNewPasswordAsync(string newPassword, CancellationToken cancellationToken);

Parameters

  • newPassword

    A string that contains the new password.

  • cancellationToken

    The input cancellation token which can be used by the application to cancel the task before connection timeout occurs.

Return Value

Task object representing the asynchronous operation immediately without blocking the calling thread for the whole duration of opening connection.

Remarks

This method uses the ConnectionString property settings to establish a new connection. The old password must be provided in the connection string as the Password attribute value.

This method can only be called on an OracleConnection in the closed state.