FireDAC.Stan.Option.TFDTopResourceOptions.AutoConnect

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

property AutoConnect: Boolean read GetAutoConnect write SetAutoConnect

C++

__property bool AutoConnect = {read=GetAutoConnect, write=SetAutoConnect, stored=IsACS, default=1};

Properties

Type Visibility Source Unit Parent
property published
FireDAC.Stan.Option.pas
FireDAC.Stan.Option.hpp
FireDAC.Stan.Option TFDTopResourceOptions

Description

Controls the automatic management of the Active state of the connection.

Use the AutoConnect property to control the automatic management of the Active state of a connection object. The default value is True.

Setting this property to True has the following effects:

  • The connection object opens, if it is closed and the command or the dataset linked to this connection requires an active connection. Otherwise, an exception will be raised.
  • The connection object closes, if it is open and the current call requires an inactive connection. Otherwise, an exception will be raised.
  • The connection object is set to the online state, if it is offline and the command or the dataset linked to this connection requires an active online connection. Otherwise, an exception will be raised.

See Also