AnyDAC
ContentsIndexHome
PreviousUpNext
TADGUIxLoginDialog Class

The dialog allows the users to enter their DB credentials.

Group
Class Hierarchy
uADCompGUIx_TADGUIxLoginDialoguADCompGUIx_TADGUIxLoginDialog
File

uADCompGUIx

Links

Use the TADGUIxLoginDialog in AnyDAC GUI application to allow to the users:

  • enter their credentials;
  • optionally change expired password.

The dialog may be used globally by all connections in an applications or may be linked directly to TADConnection.To use the dialog globally, drop it on a form or a data module. To use dialog privately by some connection, drop component on a form and set TADConnection.LoginDialog property to this dialog. 

The dialog may track the login history. This is useful in environments, which does not require security, for example the developer workstations. In such case, set HistoryEnabled to True. The dialog will store recent credentials in registry or INI-file, as specified by HistoryStorage and HistoryKey properties. And will offer the recent credentials to the user at login. 

To limit the number of login retries an application should set LoginRetries property. 

IADGUIxLoginDialog has Forms and FMX implementations. Use Provider property to select the desired implementation.

TADGUIxLoginDialog = class(TADGUIxComponent, IADGUIxLoginDialog);

Establishing Connection, TADCustomConnection.LoginDialog

ADGUIxLoginDialog1.Caption := 'Your ERP login';
with ADGUIxLoginDialog1.VisibleItems do begin
  Clear;
  Add('User_name=Your name');
  Add('Password=Your key');
end;
ADGUIxLoginDialog1.HistoryEnabled := False;

ADConnection1.ConnectionDefName := 'Oracle_Demo';
ADConnection1.LoginDialog := ADGUIxLoginDialog1;
ADConnection1.Connected := True;
What do you think about this topic? Send feedback!