CurrentUser: IRegistryKey;
The CurrentUser property returns the key containing settings of the user who logged in to the system at the moment.
Sub Main;
Var
RegKey: IRegistryKey;
Begin
RegKey := RegistryClass.CurrentUser;
Debug.WriteLine(RegKey.Name);
End Sub Main;
After executing the example name of the key that contains settings of the user entering the system at the moment is displayed in the console.
See also: