Sparx Systems Forum
Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: 1c3m4n on October 15, 2010, 11:50:24 pm
-
Hi,
i get the currently logged in user by using the command
repository.GetCurrentLoginUser(false);
Is it possible to determine the forename and surname of this user?
Have a nice weekend.
Florian
-
Florian,
I think the only way is to query the t_secuser table.
You can use Repository.SQLQuery to execute a query to the database.
Geert
-
Hi Geert,
thank you for your answer. Can you please specify what i need to write in the SQL string parameter of the SQLQuery function.
Thanks.
Florian
-
Something like
"Select u.FirstName, u.Surname from t_secuser u
where u.UserLogin = '" + loginVariable + "'"
should do the trick.
Geert
-
It works !
Thank you !
Florian