How do you open workitem if you have the ID
Accepted answer
HI , Thanks for your response, here is the code that worked for me:
IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
IWorkItem workItem = workItemClient.findWorkItemById(Integer.valueOf(split[i]), IWorkItem.FULL_PROFILE, null);
WorkItemUI.openEditor(page, workItem);
Regards
Charbel
2 other answers
Hi,
Tried the above code to open workitemUI.but it is giving the below error
java.lang.NoClassDefFoundError: com.ibm.team.workitem.rcp.ui.WorkItemUI
com.ibm.team.workitem.rcp.ui.jar is already there in the library
Comments
This will, as far as I understand it, only run inside an Eclipse or RCP extension. You would need to run this with the RTC SDK in an Eclipse client. In this case, you need to add the needed dependencies to the plugin.
It will not run in the plain java client libraries, because the platform is not available.