0

My goal is to add an activity code assignment to an activity using the P6 API, but the catch is the activity code is hierarchical. Using the methods in BOHierarchicalMap class I was able to create a BOHierarchyMap to represent the hierarchical activity code, but that class only provides a business object reference (BOHierarchyMap.ref) and not an ObjectId for the map.

In order to create an activity code assignment, I need the ObjectId of the activity code. I've searched Oracle's Primavera forums, and the Internet in general without any success.

Does anyone have experience with hierarchical activity codes using the API to create an activity code assignment? If so, any pointers would be greatly appreciated!

1 Answers1

0

It turned out simpler than I thought it would be, but without documentation, the unknown always seems more difficult.

Anyway, the simple answer is the last object id added to the map, the one that represents the highest level component of the hierarchy (opposite end from the root level, where the root level is on the far-left end of the hierarchical value) is also the object id that is used to represent the entire hierarchical activity code. The map is not actually needed, but it helps to keep track of the parent object ids as you parse through the hierarchy recursively.