+ Reply to Thread
Results 1 to 4 of 4

Time Stamp Macros and Locking

  1. #1
    Registered User
    Join Date
    07-08-2008
    Location
    Liverpool
    Posts
    2

    Time Stamp Macros and Locking

    I have an average knowledge of excel and vba as I am teaching myself how to use both by following the code and applying logic. However I am trying to create a time sheet.

    So far I have Columns
    |Start Time|Finish Time| Task| Other| Volume|
    Login/Log Out|
    Activity|
    Personal Time|

    In the start and finish times I have button macros. I am trying to have it where Staff can only click on each button once so they cant manipulate when they start and finish tasks as they do now. When they click on the macros it places a time and date stamp below the button in the cell.

    The code for the button macros are:

    Please Login or Register  to view this content.

    However I have a problem, I have tried to record a macro as my vba knowledge is very basic so that the value is locked with the current time and cant be changed. I basically need to have a feature which will lock the current time and date in the start and finish times when the button is clicked by staff.

    Id appreciate any help, Please

    EDIT: Apologies
    Last edited by VBA Noob; 07-08-2008 at 03:42 PM.

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464
    Hi, and welcome to the forum.

    Can I check one thing first.

    Is it an option to instead record the date/time the workbook is first opened in an Excel session, and the date/time it's closed? If so you could use the Workbook Open, and Workbook Before_Save events and not have to worry about the user pressing any buttons.

    Or are you wanting to capture start/finish times for different tasks performed whilst the workbook is open?

    Rgds

  3. #3
    Registered User
    Join Date
    07-08-2008
    Location
    Liverpool
    Posts
    2
    The time sheet is for a data entry team, so I need it to record time start and finishes of:

    login
    logout
    task1
    task2
    task3
    task4
    etc

  4. #4
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464
    Can you upload your workbook so that we can see your requirement in its context. Please add any notes which describe your process and interdependencies. For instance is it possible to start task 2 before task 1.

    How are you defining Login/Logout? Are these times synchronous with the workbook opening and closing or the result of clicking a button?

    Rgds

+ 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