It's all about the answers!

Ask a question

Archive EWM Project Area with Java Plain API


Angelo Corna (26358383) | asked Apr 12, 12:31 p.m.
I'm trying to archive an EWM 7.0.3 Project Area using the Java Plain API.
Here the related instructions
projectArea = (IProjectArea) processItemService.getMutableCopy(projectArea);
projectArea.setArchived(true);
processItemService.save(new IProcessItem[] { projectArea }, monitor);

Unfortunately I receive the following error
com.ibm.team.process.common.service.ProcessDataValidationException: Project area 'PRJ_ARK1' is archived, but its timeline 'Main Development' is not.
I'm able to retrieve the timeline but I don't know how archive it.
Please can you help me to solve this issue?

Thanks in advance. Bye.


Comments
Ralph Schoon commented Apr 12, 1:30 p.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

Bonus before weekend:

Find the IProjectArea or ProjectArea class item related to the timeline. If needed cast and use the archive method. Add the changed processItem to the IProcessItem array IProcessItem[]. Perform the save.


Angelo Corna commented Apr 13, 9:44 a.m. | edited Apr 15, 2:39 a.m.
Hi Ralph,

thanks for your response.
I've also found this method which seems to archive project area and teamline
processItemService.archiveProcessItem(projectArea, monitor);
Is it equivalent of your suggestion?

Bye.

Ralph Schoon commented Apr 15, 2:40 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

I would try it out.

Be the first one to answer this question!


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.