It's all about the answers!

Ask a question

How to get all Projects Present in RTC by using server api?


Pavan M (393) | asked Mar 20 '20, 3:01 a.m.
I have created projects in ccm ex: A, B, C and I am able to get only one project by using the below code by using server api.


                IProjectAreaHandle projectAreaHandle = (IProjectAreaHandle) newState.getProjectArea();
                IProjectArea projectArea=(IProjectArea)itemService1.fetchItem(projectAreaHandle, null);

Now I need to get total three projects. Any suggestions?
Thanks

One answer



permanent link
Ralph Schoon (63.1k33645) | answered Mar 20 '20, 3:38 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

 Why would you want that? What have you created? What purpose does that have (if any)? What projects and what relationship to the current operation do they have? I would have a ton of suggestions if there was a question that had any details. See https://jazz.net/forum/questions/203755/how-should-i-ask-a-question-in-the-forum-if-i-want-to-receive-useful-answers for what to consider when asking such questions.


Comments
Pavan M commented Mar 20 '20, 3:55 a.m.
Hii Ralph ,

 I need to create a Parent workitem in one project and I use one childcount custom attribute in that, I will provide some integer value to that in parent workitem, based on that count, I need to create childwork items in another project. I am trying to do this.

Ralph Schoon commented Mar 20 '20, 4:52 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
Obviously you need an indicator for the other project area. E.g. have a name/ID in the configuration, or an attribute at the work item or whatever. Your information does not provide any hints.

In general

com.ibm.team.process.internal.common.service.IProcessService allows to find process areas. 
com.ibm.team.workitem.common.IWorkItemCommon allows to search for process areas

With no more data, I have no idea. 

Your answer


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.