MS-Project: GUID preservation when moving task between master/sub-projects and/or assistance with macro solution
A. I would like to know if there is any way to move a task between projects and preserve the GUID?
B. If this is not possible, then If someone could help me with a macro that would facilitate this.
I think clarification on this issue would help the community in general as I don't think I am the only one who has had this issue.
A. When trying to move a task from either a master project to a sub-project or vice versa gives the following error:
You cannot move a task or resource from one file into another. Try copying the task or resource and then pasting it into the other project.
I realise that this is probably because the task is considered a unique item to that schedule. After doing high level planning, I like to split logical sub-projects out, but work may have already commenced and I use the GUID downstream so I need it preserved.
B. I am not adverse to a macro task moving solution and I think the pseudo code would be something like this:
1) User selects tasks to move
2) User Clicks Button
a. Macro copies GUID and resources into a spare text fields
b. Macro cuts the selected tasks out
3) User selects where tasks needs to be pasted
a. Macro prompts as to where tasks should be moved to OR
b. User selects row where tasks should be inserted and clicks another button which initiates the pasting component of macro / second pasting macro
4) Macro pastes in tasks
5) Macro updates newly generated GUID with copied GUID and also the resources
After having a look through Project 2013 SDK, I cannot see how to set GUID.
Plus I am a bit rusty in the VBA department.
Any help would be appreciated.
Cross Posted on http://stackoverflow.com/questions/20447450/ms-project-guid-preservation-when-moving-task-between-master-sub-projects-and-o
The GUID field is read only and can only be set by Project. VBA can only do pretty much what you can do manually, so VBA can't set the GUID either.
Your only solution is to copy the GUID to a custom text field and then in your code, if a GUID does not exist, search for it in the Text field.
Rod Gill Project Management
- Proposed as answer by Andrew Simpson Wednesday, February 05, 2014 8:53 AM
Rod's right - can't be done.
I find GUID isn't the best field to use for referencing tasks, as it can change if your schedule corrupts and needs rebuilding, which I find is prone to happening in a master/sub structure.
Three things I'd humbly recommend - I reckon you could achieve what you're looking for by implementing 1&2, or just 2&3 only.
1 - Choose different field to reference your tasks. I'd recommend using a custom field and coming up with a numbering convention for the tasks. That would then be maintained if you needed to rebuild that schedule at a later date, and could be kept when moving tasks between different sub-projects in the structure.
2 - Stop putting tasks in the master schedule. The master schedule is the most prone to corruption, so keep it as just a list of the inserted sub-projects, so that when (not if) it does get corrupted, you can easily rebuild it. If you've got task details in there, it makes reconstructing your master schedule much more difficult, especially if they have links to other parts of the schedule. If you need a place to put these roughly scheduled tasks before they are delegated out to specific sub-projects, have a sub project called something like "High Level Planning" to contain this content.
3 - Once you've got a "High Level Planning" sub-project, make sure you've got tasks delegated out to real sub-projects before work commences on them. If you formalised Rolling Wave Planning across your projects you'd be in a good position to enforce this. There are always tasks that creep up unexpectedly, so its not always achievable, but its a reasonable aspiration to
Sorry we can't provide you with the technical solution you're looking for, but I think these recommendations would really help protect your project files from corruption and help you out.
I hope that helps,