This post is not about the horror movie but about “I Know What You Did Last Update”
Project 2013 includes Created field to tell the date and time when the task or resource was added to your plan
In Gantt Chart view …
In Resource Sheet view …
Every time you update your plan, you lose track of which ones you updated. The problem is Project doesn’t have a field to tell when the task is last updated.
You need to write a small VBA to code to handle this requirement. We will be using a custom date field (Date1) to store the current date and time when the task is updated and here is how it goes.
1. Click View tab. Click Macros dropdown and select Visual Basic
2. In the Visual Basic Editor, on the option menu for VBAProject, choose Insert, and then choose Class Module to create a class named Class1.
3. You can rename the class module in the Properties pane. In the following examples, the class is named Events.
4. You must create a new object using the WithEvents keyword in a class module
Public WithEvents App As Application
5. Now change the object and procedure to “App” and “ProjectBeforeTaskChange”. ProjectBeforeTaskChange event will be fired for every task that is changed
6. Within this sub-routine include the below code
7. You need to bind the current Application object to the App object declared in the class to fire the events. Open the ThisProject module and paste the below code. This code declares an object X of type Events (the class module we created earlier), and sets the current Application object to the App object of Events class module
8. Save the changes.
9. Insert Date1 column in Gantt Chart. Right the column and select Custom Fields. In Custom Fields dialog, rename Date1 to Modified
10. Save the plan and close Project.
Now, reopen the plan (why? the application object is set in Project_Open event handler) and make some changes the tasks. You will notice the Modified column will get updated to current date and time
Really nice addition to the tool. I get this request from time to time and used to solve this with status date bar, however this is by far as complete as a date that can tell you if something is modified and when.
I have read a number of your posts and this one sticked out (because I’m a movie fan). Could you look into a “copy code” option just like they have on TechNet? That would make recreating your posts a lot easier. Because now I need to have 2 screens side by side and type in everything by hand.
Thanks for blogging, nice work!
Erik