From: Fredrik Karlsson on
Dear list,

This may or may not be a questions connected to Tcl, but I was
searching for a way to extract the Full Name / Real Name of the
currently logged in user on a Windows computer.

On Mac / some UNIX variants, `id -P` seems to give something you could
extract the information from, but I wonder if there is something as
general for Windows?

Does anyone know?

/Fredrik
From: Arjen Markus on
On 31 mrt, 16:03, Fredrik Karlsson <dargo...(a)gmail.com> wrote:
> Dear list,
>
> This may or may not be a questions connected to Tcl, but I was
> searching for a way to extract the Full Name / Real Name of the
> currently logged in user on a Windows computer.
>
> On Mac / some UNIX variants, `id -P` seems to give something you could
> extract the information from, but I wonder if there is something as
> general for Windows?
>
> Does anyone know?
>
> /Fredrik

Under Windows you normally have the environment variables USERID and
USERNAME
(and a couple of others) that could be a first estimate. I guess the
system
keeps its own copy around as well, as you can change these variables
at
will. But I do not know how to access these.

Regards,

Arjen
From: APN on
(lib) 53 % package require twapi
2.2.2
(lib) 54 % twapi::get_user_account_info HelpAssistant -full_name
-full_name {Remote Desktop Help Assistant Account}

On Mar 31, 7:03 pm, Fredrik Karlsson <dargo...(a)gmail.com> wrote:
> Dear list,
>
> This may or may not be a questions connected to Tcl, but I was
> searching for a way to extract the Full Name / Real Name of the
> currently logged in user on a Windows computer.
>
> On Mac / some UNIX variants, `id -P` seems to give something you could
> extract the information from, but I wonder if there is something as
> general for Windows?
>
> Does anyone know?
>
> /Fredrik

From: Roy Terry on
On Mar 31, 7:03 am, Fredrik Karlsson <dargo...(a)gmail.com> wrote:
> Dear list,
>
> This may or may not be a questions connected to Tcl, but I was
> searching for a way to extract the Full Name / Real Name of the
> currently logged in user on a Windows computer.
>
> On Mac / some UNIX variants, `id -P` seems to give something you could
> extract the information from, but I wonder if there is something as
> general for Windows?
>
> Does anyone know?
>
> /Fredrik

Look at the Tcl-provided array entry: tcl_platform(user)
From: APN on
tcl_platform(user) will only provide the login name, I believe, not
the real name associated with the login id.

On Mar 31, 10:23 pm, Roy Terry <royte...(a)earthlink.net> wrote:
> On Mar 31, 7:03 am, Fredrik Karlsson <dargo...(a)gmail.com> wrote:
>
> > Dear list,
>
> > This may or may not be a questions connected to Tcl, but I was
> > searching for a way to extract the Full Name / Real Name of the
> > currently logged in user on a Windows computer.
>
> > On Mac / some UNIX variants, `id -P` seems to give something you could
> > extract the information from, but I wonder if there is something as
> > general for Windows?
>
> > Does anyone know?
>
> > /Fredrik
>
> Look at the Tcl-provided array entry: tcl_platform(user)