getting user name

You could call the "users" shell command. It will return the short usernames of each user logged into the system.

You could do it like this:
set this_data to do shell script "users"

this would return a variable "this_data" that contains a text list of short usernames, I think...
 
If you're going to do it that way, use the command whoami rather than users. whoami only lists the currently logged in user.
 
Back
Top