From: Fredrik Karlsson on 31 Mar 2010 10:03 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 31 Mar 2010 10:55 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 31 Mar 2010 11:26 (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 31 Mar 2010 13:23 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 1 Apr 2010 22:02 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)
|
Next
|
Last
Pages: 1 2 3 Prev: Global hotkeys under X11 Next: Want / Need Genuine Google Adsense Account for Rs.300/- |