Replace Resources Process
Use the Replace Resources API process to automatically replace resources.
Process Settings
Below are the settings you must define for the Replace Resources API process.
| Setting | Description | Sample Value |
|---|---|---|
| ProcessID | This setting informs Cobra to run the Replace Resources process. | ReplaceResources |
| Project | This setting refers to the project where you want to replace resources.
The project name is case-sensitive. This setting is required. |
Demo Advanced |
| FileName | This setting refers to the full path and filename of the comma-separated value (.csv) or Excel (.xls) file containing the resource pairings to use in the replace process.
This setting is optional, and if it is not defined, you must specify the OriginalResources and ReplacementResources settings. |
C:\ProjectFiles\Deltek\Cobra\Data\ResourceList.xls |
| OriginalResources | This setting refers to the old resources to be replaced.
You must specify this setting if the FileName setting is not defined. This setting is optional and ignored if the FileName setting is specified. |
AERO1 (any resource in the resource file attached to the project) |
| ReplacementResources | This setting refers to the new resource that will replace the old resource.
You must specify this setting if the FileName setting is not defined. This setting is optional and ignored if the FileName setting is specified. |
AERO (any resource in the resource file attached to the project) |
| Criteria | Use this setting to specify the selection criterion you want to use for the process. The selection criteria change based on the project. Some selection criteria include the following:
The options are case- sensitive. This setting is optional and the default value is Total Project. |
Control Account |
| IncludeChildren |
Use this setting to determine whether the process should run against the parent code and its children.
This setting is optional and the default value is 0. |
0 |
| Selection |
Use this setting to select the portion of the project for which to replace resources. The available options depend on the selections you specified in the Criteria setting. This setting is optional and has no default value. |
1.1.1.1 / 1410 |
| IncludeCompleteCAWP |
Use this setting to determine whether the resources in completed control accounts and work packages should also be replaced.
This setting is optional and the default value is 0. |
0 |
| IncludeInProgressCAWP |
Use this setting to determine whether the resources in in-progress control accounts and work packages should also be replaced.
This setting is optional and the default value is 0. |
0 |
| Scope |
Use this setting to specify the range over which you want to run the Replace Resources process.
|
DateRange |
| StartDateLabel |
Use this setting if Scope=DateRange. This setting refers to a valid calendar label and is the starting date for the DateRange setting. This setting is optional and the default value is the starting date for the DateRange setting. |
01/31/2024 |
| EndDateLabel |
Use this setting if Scope=DateRange. This setting refers to a valid calendar label and is the ending date for the DateRange setting. This setting is optional and the default value is the ending date for the DateRange setting. |
01/31/2027 |
| ClassList | Use this setting to specify the cost classes that can be used for the process.
If the value is set to <All>, resources across all classes will be replaced. This setting is required. |
Actual,Earned |
| RunRecalculate |
Use this setting to specify whether to run the Recalculate process after completing the Replace Resources process.
This setting is optional and the default value is 0. |
0 |
| IncludeForecastClassesOnRecalculate |
If the specified class is a Forecast class with the Scale Retain EAC option set to Hours, Currency, or Hours and Currency, setting the value to 1 will include the Forecast class values when you run the Recalculate process after completing the Replace Resources process. This setting is optional and the default value is 0. |
0 |
Sample Scripts
Below are sample script files for the Replace Resources API process.
FileName Setting Specified
[Process019]
ProcessID=ReplaceResources
Project=Demo Advanced
FileName=C:\Project Files\Deltek\Cobra\Data\ResourceList.XLS
Criteria=Control Account
Selection=1.1.1.1 / 1410
IncludeChildren=0
IncludeCompleteCAWP=0
IncludeInProgressCAWP=0
Scope=DateRange
StartDateLabel=01/31/2024
EndDateLabel=01/31/2027
ClassList=Actual,Earned
RunRecalculate=0
IncludeForecastClassesOnRecalculate=0
OriginalResources and ReplacementResources Settings Specified
[Process019]
ProcessID=ReplaceResources
Project=Demo Advanced
OriginalResources=AERO1
ReplacementResources=AERO
Criteria=Control Account
Selection=1.1.1.1 / 1410
IncludeChildren=0
IncludeCompleteCAWP=0
IncludeInProgressCAWP=0
Scope=DateRange
StartDateLabel=01/31/2024
EndDateLabel=01/31/2027
ClassList=Actual,Earned
RunRecalculate=0
IncludeForecastClassesOnRecalculate=0