+ Reply to Thread
Results 1 to 4 of 4

How to retrieve username with VBA?

  1. #1
    Registered User
    Join Date
    09-16-2012
    Location
    Brussels, Belgium
    MS-Off Ver
    Excel 2003
    Posts
    12

    How to retrieve username with VBA?

    Hello,

    In a workbook where a lot of people enter information, I'm looking for a way to see who filled in which cell.
    My sheet is protected, only cell C2+D2, C3+D3, ... have to be filled in.
    In cell E2, E3, .... I want to see the user who made the changes with VBA retrieving the username.

    Can anybody help me?
    Last edited by dries_v; 08-06-2014 at 08:29 AM.

  2. #2
    Valued Forum Contributor
    Join Date
    09-21-2011
    Location
    Birmingham UK
    MS-Off Ver
    Excel 2003/7/10
    Posts
    2,188

    Re: How to retrieve username with VBA?

    Environ("Username") or Application.Username
    Hope this helps

    Sometimes its best to start at the beginning and learn VBA & Excel.

    Please dont ask me to do your work for you, I learnt from Reading books, Recording, F1 and Google and like having all of this knowledge in my head for the next time i wish to do it, or wish to tweak it.
    Available for remote consultancy work PM me

  3. #3
    Registered User
    Join Date
    09-16-2012
    Location
    Brussels, Belgium
    MS-Off Ver
    Excel 2003
    Posts
    12

    Re: How to retrieve username with VBA?

    Quote Originally Posted by nathansav View Post
    Environ("Username") or Application.Username
    Thank you for this.
    Since I am a beginning user, I followed your signature suggestions and looked some stuff op on google etc.

    I created this code:
    Please Login or Register  to view this content.
    This works fine, except, when I change the original value in eg H6, it starts filling username en date-time in offset next to the previous username en date-time.
    I assume the wrong part of the code is "End(xltoleft)". With what should I replace?

  4. #4
    Registered User
    Join Date
    09-16-2012
    Location
    Brussels, Belgium
    MS-Off Ver
    Excel 2003
    Posts
    12

    Re: How to retrieve username with VBA?

    Was able to solve it myself using this code:

    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Mac VBA - Get Mac username
    By stcharun in forum For Other Platforms(Mac, Google Docs, Mobile OS etc)
    Replies: 3
    Last Post: 01-28-2013, 05:55 PM
  2. [SOLVED] Username and Password Form - Show Username in Sheet
    By ryan180 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-24-2013, 07:06 PM
  3. Retrieve File names from a folder with last modified username
    By elavarasans in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 01-10-2013, 12:48 PM
  4. [SOLVED] Username Log
    By PaulJ in forum Excel General
    Replies: 8
    Last Post: 03-01-2006, 07:55 AM
  5. [SOLVED] Username Log
    By PaulJ in forum Excel General
    Replies: 0
    Last Post: 03-01-2006, 05:05 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1