+ Reply to Thread
Results 1 to 5 of 5

Time and date stamp

  1. #1
    Registered User
    Join Date
    06-27-2007
    Posts
    26

    Time and date stamp

    Hi


    I am loooking for either a forumla or some vba that will enable me to log when a cell is popoluated.

    Column Q is where the data is populated and what i need is someway to put the excel User Name, time and date into the next cell in column R

    Q R

    yes testusername - 24092007-1515

    Does that make sense?

    Cheers

    Nuno

  2. #2
    Forum Contributor VBA Noob's Avatar
    Join Date
    04-25-2006
    Location
    London, England
    MS-Off Ver
    xl03 & xl 07(Jan 09)
    Posts
    11,988
    This link may get you started

    http://www.mcgimpsey.com/excel/timestamp.html

    this will return the excel user name

    Please Login or Register  to view this content.
    if you need windows user name then take a look at this link

    http://www.exceltip.com/st/Function_...Excel/452.html


    VBA Noob
    _________________________________________


    Credo Elvem ipsum etian vivere
    _________________________________________
    A message for cross posters

    Please remember to wrap code.

    Forum Rules

    Please add to your signature if you found this link helpful. Excel links !!!

  3. #3
    Registered User
    Join Date
    06-27-2007
    Posts
    26
    I have figured it out...


    Please Login or Register  to view this content.

  4. #4
    Forum Contributor VBA Noob's Avatar
    Join Date
    04-25-2006
    Location
    London, England
    MS-Off Ver
    xl03 & xl 07(Jan 09)
    Posts
    11,988
    Good to see

    VBA Noob

  5. #5
    Forum Contributor
    Join Date
    03-24-2005
    Location
    Wisconsin
    MS-Off Ver
    2007
    Posts
    378

    You might want to change one thing.

    [QUOTE=nuno]I have figured it out...
    Please Login or Register  to view this content.
    Many companies set up a standard image with the company name as the standard Office UserName (Application.UserName). If that is the case for your company, that will be the username inserted.

    Changing
    Please Login or Register  to view this content.
    will use the individual login name.
    Changed code
    Please Login or Register  to view this content.
    I know Environ("username") works in Windows NT and XL using Office 2000 or Office 2003 without having to do any API calls.

    As for the date & time stamp, the following code will give a variable in the form of YYMMDD - hhmm. I usually make the date & time stamp format this way for sorting purposes. Just rearrange the order to give the format you desire. I am sure this can be made more efficient, but it has worked for me for several years...

    Please Login or Register  to view this content.
    Last edited by DCSwearingen; 09-24-2007 at 11:48 AM.
    Thanks!
    Dennis

    I am using Windows 7 and Office 2007, all of my posts are based on this.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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