PgDAC

TCustomDAConnection.PerformConnect Method

Establishes a connection to the server regardless of the LoginPrompt property.

Class

TCustomDAConnection

Syntax

procedure PerformConnect(Retry: boolean = False);

Parameters
Retry
When the Retry argument is set to False (default), the BeforeConnect event handler is called before establishing the connection.

If Retry = True, BeforeConnect is not invoked.

Remarks

Unlike the Connect method, the PerformConnect method establishes a connection regardless of the LoginPrompt property. When PerformConnect is called with LoginPrompt = True, the Connection Dialog is not displayed, and the OnLogin event handler is not invoked. After establishing the connection, the AfterConnect event handler is triggered.

Note: PerformConnect does not handle exceptions. Exceptions should be handled as usual in the calling code.

See Also

© 1997-2024 Devart. All Rights Reserved. Request Support DAC Forum Provide Feedback