Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
al al is offline
external usenet poster
 
Posts: 363
Default Obtain User ID

Using Visual Basic in Excel, how do I obtain the user ID of the user opening
the file?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,934
Default Obtain User ID

Are you looking for this?...

Application.UserName

--
Rick (MVP - Excel)


"AL" wrote in message
...
Using Visual Basic in Excel, how do I obtain the user ID of the user
opening
the file?


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 59
Default Obtain User ID


Using Visual Basic in Excel, how do I obtain the user ID of the user
opening the file?


http://www.EXCELGAARD.dk/Lib/UDFs/USERINFO/



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default Obtain User ID

Use

Environ("Username")

This returns the Windows user name.

Cordially,
Chip Pearson
Microsoft Most Valuable Professional
Excel Product Group, 1998 - 2009
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)

On Thu, 26 Mar 2009 11:24:01 -0700, AL
wrote:

Using Visual Basic in Excel, how do I obtain the user ID of the user opening
the file?

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8,520
Default Obtain User ID

Few more.

If you want to check the domain and user name use the below ...

'-----Retrieve Domain Name
' Reference Active DS Type Library Tools|Reference
Dim strAD As New ADSystemInfo
strDomainname = strAD.DomainShortName

'-----Get User Name
Set objNet = CreateObject("WScript.NetWork")
strUserName = Trim(objNet.UserName)

If this post helps click Yes
---------------
Jacob Skaria


"AL" wrote:

Using Visual Basic in Excel, how do I obtain the user ID of the user opening
the file?

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How To Obtain The Top 10% SMH Excel Discussion (Misc queries) 4 March 26th 08 01:09 PM
How can I obtain a calendar that will go from Jun 06 to Sep 07? KFA Excel Discussion (Misc queries) 1 June 2nd 06 07:48 PM
Obtain a Process ID Frank DeLuccia Excel Programming 5 April 27th 04 06:50 PM
Need to know how to obtain this...please 0o0o0[_9_] Excel Programming 2 October 18th 03 04:28 PM


All times are GMT +1. The time now is 11:45 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"