I would like to create simple code that tracks how long it takes a person to build a part. When the person using the database double clicks on a cell (complete rebuild of part(field in a table)) the code then looks at the event status of the part the person is working on and records something. There are 3 event statuses (start, pause, stop).
There are 2 ways that I am keeping track of tools, Event Number and Ticket Number. The event number is the uniqueID for each event that will have a autonumber datatype. The Ticket Number will be used to track multiple occurrences of an event on one tool. ex. Taking into consideration if they pause the building process, holidays, and weekends, etc...[times they are not building the tool]
If the event status = start, then a dialog box pops up and it say "Would you like to PAUSE or STOP making a part?".
- If the person clicks PAUSE
- the code updates the event status to PAUSE
- and puts the time that it was clicked as the value in a cell (complete rebuild of part (field in a table))
- If the person clicks STOP
- the code updates the event status to STOP
- It will enter the current date/time in the cell (complete rebuild of part (field in a table))
- ex......Me.Complete_Rebuild_Of_Part=Now()
If the event status = Pause (previously it was Start)
- Create a new record in a table with the same part number and ticket number. BUT a new event number.
- Take the previous time the part was paused and make it that time the new time for (start rebuild of part (field in a table))
If the event status = Stop
- Create a new record in the table that will have a new ticket number and event number.
- so you can start tracking how long it takes to rebuild an entirely new part.